LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

curve fitting

I want to fit my data to some gaussian. I don't know any coefficients. Can anyone tell me how can I compare my data set to some arbitrary gaussian.?

In anticipation of reply.
priiyank
0 Kudos
Message 1 of 5
(3,287 Views)
Assuming that your data has a Gaussian distribution then the Gaussian (normal) curve is defined by the mean and the standard deviation, both of which can be found using the Standard Deviation and Variance function under the Probability and Statistics portion of the Mathematics menu.

Based on your question I suspect that your data is not Gaussian in nature and you are wanting to make it into a Gaussian form, as in a professor grading on the curve. For this you could define a mean and standard deviation, sort the data points from smallest to largest, and then step through the array assigning values for each data point which fits the probability curve (i.e., if there are 100 data points then the 1st data point would correspond to the point below which 1% of the
data lies). With this method you need to make sure that you monitor cases where more than one sample have the same value. There may be other ways to do this about which I am not aware.

Hope that helps.
0 Kudos
Message 2 of 5
(3,287 Views)
I assume you have a curve that you want to fit to a gaussian function. I would just use Levenberg_marquardt. Contact me at caltenba(AT)ucla.edu and I'll send you a simple example.
0 Kudos
Message 3 of 5
(3,287 Views)
Could you post it to the forum as well? So that any interested person can benefit?

Best regards

-Tanveer
Best wishes

- Tanveer
0 Kudos
Message 4 of 5
(3,287 Views)
I am not very certain if you can do it, if you do not have any guess
coefficients. It is a known problem that if the guess coefficients are too
far away from the real values, the fitting can go wild.

However if you have some sort of idea what the coefficients-area,
offset,FWHM and center are, you can just use a normal Lev-Mar fitting
function to do the job.

-Fan
"pshuk256" wrote in message
news:5065000000080000002AB70000-1068850981000@exchange.ni.com...
> I want to fit my data to some gaussian. I don't know any coefficients.
> Can anyone tell me how can I compare my data set to some arbitrary
> gaussian.?
>
> In anticipation of reply.
> priiyank
0 Kudos
Message 5 of 5
(3,287 Views)