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
 Forum for Origin C
 separate fit results in 1wks

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
deomlew Posted - 11/13/2006 : 05:59:32 AM
Origin Version (Select Help-->About Origin): origin 7.0 sr04
Operating System: windowsxp

Hello,

I have a new question. Using the example "automation", I can now, via drag and drop, plot and fit my datafiles. It would be nice though if I could also get the fit results of all these separate files in one worksheet. Besides, it would be very convenient if all the graphs would also be shown in one plot. The problem is though that all my datafiles are processed separately. Does anyone know if there is an origin example that can give me some clues of how to implement this in my script?
Tnx!
4   L A T E S T    R E P L I E S    (Newest First)
deomlew Posted - 11/14/2006 : 03:36:17 AM
great! that was it for now:)
tnx
Mike Buess Posted - 11/13/2006 : 12:51:25 PM
Glad the first part is working. I think you can create the graph you want by replacing
GraphPage grphAllPlots;
with
GraphPage grphAllPlots("AllPlots");

Mike Buess
Origin WebRing Member
deomlew Posted - 11/13/2006 : 12:27:18 PM
Tanks again! I am getting my fit parameters in one wks now.
Regarding the all-in-1-plot: it is the raw data that I would like to have in one graph. I tried it in the following way, but instead of one plot, origin returns separate plots, renaming them by adding a number (allplots, allplots1, allplots2, etc.)

// Declare a curve object using x,y columns of worksheet
Curve crvData(wksData, 2, 3);

// Get name of curve
string strYDataName;
crvData.GetName(strYDataName);

// Get graph template name
string strGraphTemplateName = LabTalk.System.Path.Program$
+ "Samples\Programming\Automation\Automationb.OTP";

//create graph allplots in case that it is not already existing
GraphPage grphAllPlots;
if( !grphAllPlots )
{
bool cRetG = grphAllPlots.Create(strGraphTemplateName, nOptionG);
grphAllPlots.Rename("AllPlots"); // Rename the worksheetPage to allplots
}

// Declare active layer in current graph page
GraphLayer grphLayerAllPlots = grphAllPlots.Layers();

// Plot data curve to active layer
int mPlot = grphLayerAllPlots.AddPlot(crvData, IDM_PLOT_SCATTER);
grphLayerAllPlots.Rescale();
Mike Buess Posted - 11/13/2006 : 10:06:11 AM
This is an easy way to collect all parameters into one worksheet...

1. Download and install the MultiFit addon from the File Exchange.
2. Insert the line void mf2wks(string); after #include <Origin.h> in your version of Automation.c.
3. Insert the line mf2wks("Params"); before fldRootFolder.Activate();.

All parameters will be appended to a worksheet like that shown in the MultiFit description. I think we need to see your current code before suggesting changes to plot all data in one graph. Also, do you want to plot raw data, fitted curve or both?

Mike Buess
Origin WebRing Member

Edited by - Mike Buess on 11/13/2006 10:22:04 AM

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