| Re: Alternate plot scales [message #13887 is a reply to message #13881] |
Wed, 06 January 1999 00:00  |
davidf
Messages: 2866 Registered: September 1996
|
Senior Member |
|
|
Brad Gom (gombg@uleth.ca) writes:
> I'm looking for a way to draw a secondary plot scale. The problem is
> that I want the second axis scale to be a function of the first.
>
> For example, the lower x-axis is a standard linear scale, and the upper
> x-axis is the square of the lower axis. Now the tricky part: I want the
> tickmarks for the second axis to occur at regular -numeric- (not
> graphical) intervals.
>
> eg. if the lower scale had ticks at [4,5,6,7,8], then it would be
> trivial to have the upper axis with the corresponding ticks labeled
> [16,25,36,49,64]. What I want is for the ticks on the upper axis to
> occur at some interval like [20,25,30,35,40,45,50,55,60] so that their
> spacing on the plot gets tighter but the numeric interval is constant.
I don't see any problem. The AXIS command will accept the normal
XTICKS, XTICKV, etc. keywords. You can make the axis as elaborate
and as tightly spaced as you like. Just remember to set the SAVE
keyword on the call so subsequent OPLOTS will use the new axis.
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Progamming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|
|