I do not believe that any of those calculations are based on the pdf, 
frequency of occurrence-histogram. This, (1, 2,2, 4, 2,5,4) and not this 
(1,3, 0,2,1). The latter are the frequencies of occurrence for 1,2,3,4,5.

John Hunter wrote:
> On Tue, Dec 1, 2009 at 6:32 AM, Wayne Watson
> <sierra_mtnv...@sbcglobal.net> wrote:
>   
>> Is there some statistics function that computes the mean, std. dev., 
>> min/max, etc. from a frequency distribution?
>>     
>
> numpy has many functions for basic descriptive statistics.  If "data"
> is an array of your data, you can do (import numpy as np)
>
> mean: np.mean(data)
> median: np.median(data)
> standard deviation: np.std(data)
> min: np.min(data)
> max: np.max(data)
>
> In scipy.stats, there are many more (skew, kurtosis, etc...)  See
> also, this example:
>
>
> http://matplotlib.svn.sourceforge.net/viewvc/matplotlib/trunk/py4science/examples/stats_descriptives.py?view=markup&pathrev=4027
>
> JDH
>
>   

-- 
           Wayne Watson (Watson Adventures, Prop., Nevada City, CA)

             (121.015 Deg. W, 39.262 Deg. N) GMT-8 hr std. time)
              Obz Site:  39° 15' 7" N, 121° 2' 32" W, 2700 feet  
                
          The popular press and many authorities believe the number
          of pedofiles that prowl the web is 50,00. There are no
          figures that support this. The number of children below
          18 years of age kidnapped by strangers is 1 in 600,000,
          or 115 per year. -- The Science of Fear by D. Gardner
 
                    Web Page: <www.speckledwithstars.net/>


------------------------------------------------------------------------------
Join us December 9, 2009 for the Red Hat Virtual Experience,
a free event focused on virtualization and cloud computing. 
Attend in-depth sessions from your desk. Your couch. Anywhere.
http://p.sf.net/sfu/redhat-sfdev2dev
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to