Fixed bug in mean/variance methods where x/y coordinates were swapped