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
 How to set the initial parameter

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
scopio98 Posted - 04/20/2004 : 08:58:11 AM
How to set the initial parameters for user-defined function?

I followed the instruction Defining Your Own Function of Two Variables in the Advanced Mode in Some General Notes on the Advanced Mode of the Nonlinear Least Squares Curve Fitter in Origin help file.

After that, I defined a new function for myself and found I don't know what the initial parameters value is. I tried to give values for them but always got error message with information "Likely caused by errors in user defined formula or poor parameter initialization".

I'll be very appreciated for any help from you!

Thanks in advance!


2   L A T E S T    R E P L I E S    (Newest First)
easwar Posted - 04/20/2004 : 11:23:40 AM
Hello,

There is a dialog in the NLSF tool in which you can enter parameter initialization code. This dialog can be brought up using the NLSF tool menu command: Scripts|Parameter Initialization

You then have the following choices:
-> Enter Origin C code to examine the raw data and assign initial parameter values similar to how we do this for our built-in functions. There are many basic analysis functions in Origin C such as xatymax (x value at max y value) etc. that you can use and these are documented under Global Functions->Analysis topic in the programming help files
-> Enter LabTalk script code to perform initialization. In this case, uncheck the "Use Origin C" check box
-> Just enter constant values for each parameter, to be used as the initial value (uncheck Use Origin C)

Easwar
OriginLab

Mike Buess Posted - 04/20/2004 : 10:24:57 AM
nlsf.pn=value; // set the value of the nth parameter to value
%A=nlsf.nn$; // assign the name of the nth parameter to %A



Mike Buess
Origin WebRing Member

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