aya...@gmail.com
unread,Jan 8, 2015, 10:17:15 AM1/8/15Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to jstat-...@googlegroups.com
Hi,
I think there is an error in the docs for the stdev() Vector function.
Running the function with and without the flag set returns the following:
> jStat.jStat.stdev([155, 160, 152, 168, 172, 169, 172, 165, 158, 159, 201, 219, 250, 300, 264, 223, 189, 199, 208, 187, 147, 250, 270, 223, 217, 197, 184, 158, 199, 201, 223, 217, 197, 219, 186, 164, 151, 192, 136, 207, 254, 213, 198, 203, 196, 165, 160, 277, 265, 116]);
39.26079469394373
> jStat.jStat.stdev([155, 160, 152, 168, 172, 169, 172, 165, 158, 159, 201, 219, 250, 300, 264, 223, 189, 199, 208, 187, 147, 250, 270, 223, 217, 197, 184, 158, 199, 201, 223, 217, 197, 219, 186, 164, 151, 192, 136, 207, 254, 213, 198, 203, 196, 165, 160, 277, 265, 116], false);
39.26079469394373
> jStat.jStat.stdev([155, 160, 152, 168, 172, 169, 172, 165, 158, 159, 201, 219, 250, 300, 264, 223, 189, 199, 208, 187, 147, 250, 270, 223, 217, 197, 184, 158, 199, 201, 223, 217, 197, 219, 186, 164, 151, 192, 136, 207, 254, 213, 198, 203, 196, 165, 160, 277, 265, 116], true);
39.65939166122919
It looks like passing in 'true' as the flag returns the *sample* standard deviation and by default, the function returns the *population* standard deviation.
Am I looking at this cross-eyed?
Thanks,
Andy