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
 Statistics on ranges within datasets? Pick Peaks toolbar?

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
a_user Posted - 08/13/1998 : 12:30:00 PM
I have two questions. First, is there a way of using the sum function
on a range within a dataset, rather than the whole dataset? I realize
I can copy the range of interest into a dataset of its own and perform
the sum function on it, but it'd be nice if the sum function had an
option like sum(dataset,firstpoint,lastpoint). Second, is there any way
to use the Pick Peaks toolbar to pick negative peaks (minima) rather
than positive peaks (maxima)? Again, I can do a workaround by multiplying
my dataset by -1 before finding the peaks, but it'd be nice to not have
to do that.
1   L A T E S T    R E P L I E S    (Newest First)
a_user Posted - 08/13/1998 : 12:33:00 PM
Sum Function Used on a Range

SUM FUNCTION ON A RANGE

The sum function can be executed on a range of data by using a short script.
This needs to be executed as a block of script so that everything gets passed
to the interpreter at the same time. Otherwise after the screen refreshes,
the
range will reset automatically thereby allowing the sum function to operate
on the entire column.

Example code for the above is:

def RangeSum{
set %1 -bs %2; /* set starting row to 2nd parameter */
set %1 -es %3; /* set ending row to 3rd parameter*/
sum(%1); /* apply sum function */
set %1 -e; /* reset range */
};

This will now define the macro RangeSum which will accept 3 parameters.
To use the macro, use the following syntax:

RangeSum Data1_b 5 20;

This will perform the sum function on the dataset Data1_b for rows 5 through
20.

PICK PEAKS TOOLBAR

Unfortunately, the pick peaks toolbar cannot find negative peaks at this time.
This is a very good suggestion which we will hopefully implement in a future
version. Until that time, your best work around is to, as you stated,
multiply
the dataset by -1 before finding the peaks.


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