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
 Origin Forum
 Change X-axis Attributes for a Group of Plots
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

lpsimoni

USA
Posts

Posted - 03/02/2008 :  9:01:41 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Version (Select Help-->About Origin):
Operating System:windows xp

I would appreciate some help or thoughts.

I have one worksheet that contains "time" in the first column and about 20 other parameters in the remaining columns.

I plot all the parameters as a function of time on individual graphs.

When I refresh the data (i.e., reload the worksheet), the new set of data may be for a different length of time.

Can I easily modify the x-axis attributes (e.g., range, tick marks)of all the graphs with one operation? I don't want to edit each individual graph every time I change data.

Thanks,
Len

Deanna

China
Posts

Posted - 03/02/2008 :  10:12:49 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Len,

I suggest running a LabTalk script script each time after the data is updated. The script can be programmed to update the graph scales. For example, the below script rescales all graphs in the project:

doc -e p {rescale;};


After the data is updated, you can copy the script in the Script Window / Command Window and execute it. If you wish to perform other modification to the axes, please modify the script above.

If you are using the Import Wizard to import the data into the data worksheet, you may even opt to put the script in an import filter so that it can be executed automatically after the importing is done.

Let us know if you have more questions.

Deanna
OriginLab Technical Services
Go to Top of Page

lpsimoni

USA
Posts

Posted - 03/03/2008 :  08:37:15 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Deanna,

Thanks for the information.

I will try.

Len
Go to Top of Page

lpsimoni

USA
Posts

Posted - 03/03/2008 :  12:19:55 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Deanna,

I wasn't successful.

Can you give me the script for the following change to the x-axis range (i.e., time scale)?

I should be able to understand the methodology for changing other x-axis attributes based on your answer.

Change the x-axis range from 0-1000 to 500-1200.

Thanks,
Len
Go to Top of Page

Fay_Guo

China
Posts

Posted - 03/04/2008 :  03:40:04 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Len,

This script
doc -e p {layer.x.from=500; layer.x.to=1200}; 
can change the X-axis scales of all graphs in your current project to 500 - 1200.


Fay

Originlab Technical Services
Go to Top of Page

lpsimoni

USA
Posts

Posted - 03/04/2008 :  11:46:49 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thank you.

It works - very well.

Saves me a lot of time.
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