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
 Origin Forum
 X Axis Scale Problem

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
psgst Posted - 12/04/2006 : 11:43:22 AM
Origin Version (Select Help-->About Origin): 7.5 SR6
Operating System: Win XP

Hi,

I am having an issue with the apparent scale of my X axis in multiple graphs that I am creating from a standard ASCII data set using a LabTalk script. This is occurring on two different histograms in slightly different ways and so I will describe both and have attached a screenshot of each. These graphs have been correctly drawn in the past from the same script, and so I am wondering if I have inadvertently changed a setting on Origin?

The first is a histogram of particle length, with cumulative frequency line also included. Normally, and previously, this graph would draw with the X axis in increments of 50, but X axis is packed with numbers. In the script we do not set any attributes to layer1.x besides showGrids on and majorColour to 1. If I open the script window with this graph selected and enter: layer1.x.inc = 50 , then the X axis redraws, the histogram columns do not change, and I am presented with only one major tick: which holds the value of 349.5 and is approximately just over half the way across the X axis. I find this very odd, and inexplicable. The tick data is coming from the dataset, and so it isn't a case of the data being numeric, and the divide by factor being incorrect.

On the second graph the problem is similar. A histogram that is always within the range 0 to 1.1, with increments of 0.1 across the X, which would always previously draw correctly. The graph seems to have been enlarged to only focus upon the bottom left corner. I have set the following attributes to layer1.x in the script:


layer1.x.label.divideBy = 1;
layer1.x.from = 0;
layer1.x.inc = 0.1;
layer1.x.to = 1.1;
layer.x.showgrids = 1;



However, this isn't working. If I change layer1.x.to to something along the lines of 22, we see the entire graph but the values along the X axis are incorrect, and are in the order of:- 0.025, 0.475, 0.725, and 0.975. Only these four values are displayed - certainly not the increments of 0.1 that were specified.

These two problems seem linked, but I cannot see where I am going wrong. Can anyone shed some light on this matter?



Edited by - psgst on 12/04/2006 11:45:14 AM
1   L A T E S T    R E P L I E S    (Newest First)
greg Posted - 12/05/2006 : 09:24:21 AM
Anytime you see a disparity between an axis range and the range of the data for that axis, check for one of two things:

1. Plotting against Row number
If you look at the Data menu for the plot, you can see something like Data1:1/1(X),B(Y) which indicates an 'artificial' X dataset starting with 1 and incrementing by 1 (Row numbers).

2. Categorical data
A dataset will plot categorically (enumerated unique values) if the column type is set as Text or the column itself is set as Categorical.
Check the Column Format and the Column menu. Also, double-click the axis labels and see if the Tick Label Type is Categorical.


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