T O P I C R E V I E W |
RafalM |
Posted - 06/07/2011 : 08:37:36 AM Origin Ver.: OriginPro 8.0.63.988 SR6 v8.0988; Operating System: Windows XP
I have 100 matrix data sets which I need to add. Is there some automatic function that would do it, as opposed to adding them manually one by one?
Thanks in advance, Rafal |
1 L A T E S T R E P L I E S (Newest First) |
Hideo Fujii |
Posted - 06/07/2011 : 12:52:35 PM Hi Rafal,
The following snippet add all existing matrices to a new destination matrix. Here, it assumes all matrices have the same size, and a matrix book contains only one sheet:
///////////////// string mm$, hh$; window -d; //duplicate to make same size matrix %M=%H; //destination mat name mm$=%M; //same (%M)=(0); //initialize %K=""; //formula string doc -e M { hh$=%H; //picked-up matrix if(hh$!=mm$) { //exclude destination %K=%M+%H; //concat a term to formula (%M)=(%K); //evaluation the formula } } /////////////////
You can run this script by pasting in Script window, highlight all lines, and press ENTER key. Please modify as needed.
--Hideo Fujii OriginLab |
|
|