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 for Programming
 LabTalk Forum
 fit limits

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
Atomfried Posted - 11/01/2004 : 11:13:19 AM
Origin Version (Select Help-->About Origin): 7.0
Operating System: Win XP

Hi,

I have written a script that performs polynomial regressions by calling the stat.pr()-function. The interesting part of it is:


worksheet -a 2;
wks.col6.type=4; // Set col(F) as X
stat.reset(); // can't see the effect :)
stat.pr.order=5;
stat.data$=%A_E; // data to be fitted
stat.fitxData$=%A_F;
stat.fityData$=%A_G;
stat.makeX.fitnpts=201;
stat.makeX.fitx1=2;
stat.makeX.fitx2=4;
stat.makeX();
stat.pr();


It works fine, but the result, i.e. the obtained parameters are always the same, no matter what limits (fitx1 and fitx2) I choose. I have the impression, that the script fits the whole curve and then just cuts off the X-values <2 an >4


What did I do wrong?

Roman
1   L A T E S T    R E P L I E S    (Newest First)
Mike Buess Posted - 11/01/2004 : 12:44:12 PM
Hi Roman,

I have not used the stat object but according to the documentation the stat.makex properties only control the curve that's created from the fit. You should be able to use the MKS1 and MKS2 system variables to limit the range of points in the data set that are fitted...

worksheet -a 2;
wks.col6.type=4; // Set col(F) as X
stat.reset(); // can't see the effect :)
stat.pr.order=5;
stat.data$=%A_E; // data to be fitted
stat.fitxData$=%A_F;
stat.fityData$=%A_G;
stat.makeX.fitnpts=201;
stat.makeX.fitx1=2;
stat.makeX.fitx2=4;
MKS1=xindex(2,%A_E); // start fitting with the point at X=2
MKS2=xindex(4,%A_E); // stop fitting with the point at X=4
stat.makeX();
stat.pr();

Mike Buess
Origin WebRing Member

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