General information
Category:
Coding, syntax & commands
>>I don't know a native command. I could probably write you a func... if you ever need it. I was reading somewhere that fox is quite good for developing mathematical functions (amongst other things) etc
>
>OK, thanks.
Couldn't resist the challenge...
FUNCTION MyStDev
LPARAMETERS tcfieldName, tcAlias
LOCAL lnReccount, lnSum, lnSquare
LOCAL lcTalk
lcTalk = SET( "TALK")
SET TALK OFF
lnReccount = RECCOUNT( tcAlias)
CALCULATE SUM( EVALUATE( tcFieldName)) TO lnSum
CALCULATE SUM( EVALUATE( tcFieldName)^2) TO lnSquare
SET TALK &lcTalk
RETURN SQRT((( lnReccount*lnSquare) - ( lnSum^2))/ (lnReccount*(lnReccount-1)))
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only