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
 Linking axes formats
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

Tom Blanpied

Durham, NC, US
1 Posts

Posted - 08/12/1998 :  5:01:00 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Hello all.

In creating links between layers, I'd like to know if there is a way to link
the axis format of the daughter to the parent. That is, I find myself very
often linking two layers and then spending a lot of annoying time making sure
the number of ticks, the tick length, the label font size, etc. are identical
between the two layers. When several plots are linked to a single parent, it
can be quite a pain to update by hand each of the details on all the
offspring.

The linking feature is terrific, but does anyone else think that it could be
improved by including this kind of feature?

Tom

a_user

USA
0 Posts

Posted - 08/12/1998 :  5:03:00 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Response

With the use of a graph template it is possible to create a number of graphs
using the same characteristics. This would include the type of plot and axes.
You can create labels and set the number of ticks and the length of the axis.
Once the template is as you wish save it using the File: Template: Save as.
Origin menu command. If you use the template name Layer.otp, then you can
create duplicates on a new layer using the Edit: Arrange all Layers menu
command. You will be prompted for the number of rows and columns. If you
only have one layer in the graph window and you specify two rows and two
columns then Origin will prompt you, "Need to create 3 more layers". When you
click on OK three additional layers will be created. All of the
characteristics will be from the Layer.otp that you previously created. Do not
forget the layers are not yet linked. You will need to go to the layer control
to link the layers. You also should remember that the axes in the different
layers will rescale when you move data into them unless you have set the axes
in the Layer.otp from the default of NORMAL to MANUAL.

The template only allows the creation of identical graph layers. If you make a
change to one of the layers, the characteristics will not change on the other
layers. That is why you will want to make the Layer.otp as complete and
accurate as possible. There are some characteristics that you can change on one
layer and have the change reflected on all of the other layers. This mainly
refers to the font characteristics used in labels. Within the Text Control
dialog box is a check box [ X ] Apply to All which allows the font change to
affect all labels in all layers of the particular graph window.

It is not yet possible to link the characteristics from one layer to another so
they will automatically change. It is possible to create a custom LabTalk
script to read lets say the number of major tick labels on the X axis from
layer one, and then set the layer two X axis to the same number. This is
explained in detail on page 139 and 140 of the Origin LabTalk Manual version
4.0

Here is a LabTalk example that will set the number of major ticks in layer two
of Graph1 to be the same as the number of major ticks in layer one.

mtick=GRAPH1!LAYER1.X.MAJORTICKS;
GRAPH1!LAYER2.X.MAJORTICKS=mtick;

You can run this script in the Script window, or you can create a button on the
graph window and place this script into the button. The button and the
underlying script will be saved when you save the template as Layer.otp When
you click on the button the script will read the number of tick labels in layer
one and place this number into the variable mtick. The next line of script
will then set the number of X Axis major tick labels to the number held in the
variable mtick, which is same as in layer one. You can add to this script and
add other characteristics to be read from Layer one and reproduced in Layer
two. You can also have the script access additional layers if they exist. It
is important to only address layers that exist.

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