powered by
weighted_var(x, w) wvar(x, w)
weighted_variance
where $w(i)' = w(i)/sum(w)$, and $w.mean(x)=sum[w(i)'*x(i)]$.
diffmap