Switched median, added mean.