Showing results for 
Search instead for 
Did you mean: 

Nonlinear Curve Fit


At the moment i am fitting a temperature profile that is equal to the sigmoid function (first picture).

But in some cases the temperature profile is not equal to the sigmoid function (second picture) and so i have to find another way to fit this profile.

White is the original temperature profile and the red/green is the fitted function.

You will see the fitting code at the end.

Can anybody help me?


Thanks, Martin

Download All
0 Kudos
Message 1 of 4

i am using the fourth formula where b and c are the fitted parameters.

0 Kudos
Message 2 of 4

One generally starts with a hypothesis, "I expect Reality to behave this way", which can also be expressed as a "model" such as "Temperature as a function of height should be a sigmoid".  You do an experiment (or take some measurements), then test your hypothesis (fit your model).  If the model fits, it does not prove your hypothesis, but can allow you to assume your hypothesis is true and then say something like "and the Critical Temperature is X degrees".  If the model does not fit, it suggests that the hypothesis is false.  The solution is to come up with an alternative hypothesis, but the hypothesis should come first!  You can always exactly fit N data points with a polynomial of degree N+1, but that has no "explanatory value" (and is highly unlikely to generalize to a second data set).


Bottom line -- come up with your own alternative fitting function, preferably one that "makes sense" in the context of your study.


Bob Schor 

0 Kudos
Message 3 of 4

Are you sure that you don't accidentally have they axes (x vs. y) swapped in some of the data sets? Maybe the hardware is hooked up incorrectly.

0 Kudos
Message 4 of 4