MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Fit Gaussian function to histogram

  • To: mathgroup at smc.vnet.net
  • Subject: [mg117695] Re: Fit Gaussian function to histogram
  • From: Richard Hofler <rhofler at bus.ucf.edu>
  • Date: Wed, 30 Mar 2011 04:08:44 -0500 (EST)

Hello,

Try this:

data=Table[Random[NormalDistribution[10,2]],{10000}];
histo=Histogram[data];
plt=Plot[2000 PDF[NormalDistribution[10,2]][x],{x,4,16}];
Show[histo,plt]

Richard


-----Original Message-----
From: cubsfan334 [mailto:cubsfan334 at gmail.com]
Sent: Tuesday, March 29, 2011 7:55 AM
To: mathgroup at smc.vnet.net
Subject: [mg117695] [mg117655] Fit Gaussian function to histogram

Hi,

I realize that I can generate a histogram from a data set using the
Histogram[{data},bin size] command, yet this only seems to create a
graphic.  Is there anyway to fit a function (preferably Gaussian) to
the histogram Mathematica creates?

Thanks!


  • Prev by Date: Re: polynomial function
  • Next by Date: OT: structure of threads
  • Previous by thread: Re: Fit Gaussian function to histogram
  • Next by thread: Re: Fit Gaussian function to histogram