I'm trying to figure out how to express the variance of a set of quaternions that are symmetric around $0.$ Therefore I know that $\operatorname{Var}(w) = \operatorname E(|w|^2)$ with $w=r+xi+yj+zk$ and $\operatorname E(|w|^2) =\int_R |x|^2f(x) \, dx$. Nonetheless, $f(x)$ has four DOF (independent) in the case of quaternions. So how to solve this ?
Thanks for the help !