The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum
 Origin Forum
 Fitting an error function to data

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
sharapova Posted - 12/11/2014 : 04:55:18 AM
Hi there, I have experimental data that seem to give a sigmoidal like shape. My supervisor told me to fit an error function (but he didn't specifiy further). Wikipedia gives me the following:

http://en.wikipedia.org/wiki/Error_function

So I have 2 problems:

1. I need to introduce fitting parameters to account for x/y shift and the curvature...I am a bit confused about the integral, but I was thinking to adjust the gaussian function inside of it, so I would substitute exp(-x2) by
A + exp(-k(x2-x0))

but maybe this is wrong and there is an easier way to do this ?

Anyways,

2. How can I implement this in Origin ? I would prefer to avoid coding since I only started using this software. I don't quite see how to insert a formula containing an integral, the more so as I am wondering whether Origin is capable of doing such a fit..

I am looking forward to your answers

Cheers
3   L A T E S T    R E P L I E S    (Newest First)
Hideo Fujii Posted - 12/12/2014 : 12:45:55 PM
Hi sharapovaA

> Maybe one of the parameters is redundant ?

I don't think so, and maybe your initial parameter values are not reasonably good enough?

> the Origin built in error function doesnt seem to be defined for negative x values

As far as I tested in my Origin 2015, erf(x) takes negative X, of course resulting erf(-x)= -erf(x). Which version of Origin are you using?

--Hideo Fujii
OriginLab

sharapova Posted - 12/12/2014 : 10:52:10 AM
Hi Hideo,

I tried to define a new user built function using the user interface (I dont know how to code in Origin) but the fit doesnt converge and Origin tells me that I might have overparametrized...
Maybe one of the parameters is redundant ?
Likewise, the Origin built in error function doesnt seem to be defined for negative x values...do you maybe have any more advice on that ?

cheers and thx in advance !
Hideo Fujii Posted - 12/11/2014 : 11:51:35 AM
Hi SharapovaA

As Origin has the built-in math function of erf(x), you can define your shifted fitting function as:
  Function Type: LabTalk
  Parameters: x0,y0,A,k
  Function: y=A*erf(k*(x-x0))+y0
This works?

--Hideo Fujii
OriginLab

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000