variance calculation is wrong
(#529)