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
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum for Programming
 LabTalk Forum
 Span to full axis range
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

J.F.P.

Germany
7 Posts

Posted - 03/20/2012 :  12:46:41 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. and Service Release (Select Help-->About Origin): 8.5.1 SR2
Operating System: Win XP

Hallo everybody,

I use NLfit in Labtalk script to fit a part of my data. When plotting the fit curve, it is only displayed in the range of the fitted data. In the NLfit dialog there is the range option to span to full axis range. Is there a similar Labtalk command?

A second question: When plotting multiple graphs in one layer, is it possible to access each of them separate to change color, line style... with Labtalk commands?

Thanks in advance for your help :)

Best regards
Jonas

Sam Fang

293 Posts

Posted - 03/21/2012 :  05:19:10 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
To span to full axis range, add the script following nlbegin.

nlgui gg 1;
gg.Graph1.XDataType.Range= 1;
nlgui gg 0;


To change a plot's line property in a layer, you can use the following script.

range p1=1!1; //The first plot
set %c -c 3; //Change the line's color
set %c -d 1; //Change the line's style.


Sam
OriginLab Technical Services
Go to Top of Page

J.F.P.

Germany
7 Posts

Posted - 03/22/2012 :  04:56:31 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks for your help Sam, it works:)

Two comments:
1. To span to full axis range with

nlgui gg 1;
gg.Graph1.XDataType.Range= 1;
nlgui gg 0;

you have to fit on the data from the graph not the worksheet.

2. To change plot properties you have to use

range p1=1!1; //The first plot
set p1 -c 3; //Change the line's color
set p1 -d 1; //Change the line's style.


Best regards
Jonas
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000