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
 Savitzky-Golay-Smoothing with 800 curves

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
centax Posted - 02/03/2011 : 2:49:50 PM
Hi everybody,

i want to use the Savitzky-Golay-Filter on a worksheet with 1 X axis and 800 y axes. is it possible to smooth all 800 curves at once? and when yes: how? :)
thanks a lot

Version: OriginPro 8.50G SR1
OS: Windows 7
2   L A T E S T    R E P L I E S    (Newest First)
centax Posted - 02/09/2011 : 09:43:54 AM
thanks a lot! it works :)
vincenth Posted - 02/07/2011 : 12:27:48 PM
Hi,

The easiest way is to loop over all the columns using a script:

int numcols = wks.ncols;
for (ii=2; ii<=numcols; ii++) {
smooth iy:=Sheet1!$(ii) method:=sg npts:=4 polyorder:=2 oy:=Sheet2!<new>;
}

Highlight the entire script in the script window and hit enter to run it. The script above assumes you have your input data in Sheet1, with X data in column 1, and n Y data columns to the right. The output data is sent to Sheet2, and will create a new X for each. If you only care about generating new Y columns, the following will work:

int numcols = wks.ncols;
for (ii=2; ii<=numcols; ii++) {
smooth iy:=Sheet1!$(ii) method:=sg npts:=4 polyorder:=2 oy:=Sheet2!(<autoX>,<new>);
}

Regards,
Vince

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