Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Generating Statistics Info
Message
De
27/05/1999 12:19:42
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
27/05/1999 12:03:55
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00223474
Message ID:
00223516
Vues:
18
>>>Can anyone direct me to any statistical generation methods/functions for VFP?
>>>
>>>I'd like to know:
>>>
>>>Mean,Mode,Median,High/Low,Std Dev...stuff like that.
>>>
>>>TIA,
>>>
>>>/Chris
>>
>>You can get average and standard deviation (as well as some others) by using CALCULATE. Check the help file for details.
>
>George,
>
>I was able to generate all I need but median. Anything for that?
>
>/Chris
"Median" ? Is it the value sitting in middle in a series ? If so and number of elements <= 65000 a simple way might be :
select myValue into array myArray where !isnull(myValue)
if type("myArray") # "U"
 if alen(myArray,1) > 1
    return myArray[floor(alen(myArray,1)/2) + 1]
 else
    return myArray[1]
 endif
endif
return .null.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform