Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Calculate STD() vs. Excel STDEV() function
Message
From
02/09/2002 08:26:30
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
02/09/2002 07:55:06
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00695910
Message ID:
00695915
Views:
12
>Dear All,
>
>My client wants to have a standard deviation calculated on his report.
>The problem is that CALCULATE STD() gives different result with FoxPro than the equivalent STDEV() in Excel.
>
>For example: group of 10 numbers 1345,1301,1368,1322,1310,1370,1318,1350,1303,1299 listed in a table gives 26.05456 in FoxPro and 27.46 in Excel.
>
>I think I need to go back to school, or maybe I am missing something, because the AVG() FoxPro function and AVERAGE() Excel function are giving me exactly the same result.
>
>Any miracles?
>
>Thanks
>
>Jonathan

Excel: "Assume that the numbers provided are a sample of the total population". VFP: "Assume that the numbers provided are the total population". The statistical formulae are different. Excel also has a formulat for the total population, which gives exactly the same answer you mention for VFP. I won't give the formula here, since the names of formulae in Spanish Excel are different. Just search Excel for statistical functions.

As for how exactly this is calculated, well, I would have to check textbooks on statistics as well. I seem to remember that the difference between the two results involves a factor which can either be "n" or "n-1" (or was it "n+1"?), depending on whether you work with the total population or with a sample.

HTH, Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform