| Re: OBJ_AXIS tick labels [message #15072 is a reply to message #14991] |
Wed, 14 April 1999 00:00   |
davidf
Messages: 2866 Registered: September 1996
|
Senior Member |
|
|
Pavel Romashkin (pavel@terra.colorado.edu) writes:
> Dave, do you set viewplane rectangle to [0, 0, 1, 1]? Do you then explicitly
> specify the location for your axis in a view? Default settings ([-1, -1, 2,
> ,2]) do not seem to make sense., axes start in the center of the screen
> then. Well, too many questions I'm afraid. Could you tell me, is there a
> procedure in your archive that does it, which I could examine to see how you
> did it?
For this particular application the viewplane rectangle is set
like this:
plotView = Obj_New('IDLgrView', Viewplane_Rect=[-.35, -.35, 1.6, 1.6], $
Location=[0,0], Color=[80,80,80])
This allows me to scale the data into 0 to 1 and have the
plot fit into the window nicely. (Normalize, which you
can find on my web page, scales into 0 to 1 by default, but
you can also use it to scale into *any* range.) I like to
use the 0 to 1 idea for plots because I'm more familiar with
it.
Sometimes I make the viewplane rectangle coordinates 0 to 1
and then I can "position" things in the window using the
same thinking I use in direct graphics. But, of course,
the coordinate system established by the viewplane rectangle
is completely arbitrary and is set up only for your
own convenience.
You can see how I set up the viewplane rectangle by looking
at the XPLOT program on my web page:
http://www.dfanning.com/programs/xplot.pro
Unfortunately, this doesn't have the ability to change data sets,
so the character dimension recomputing is not implemented there.
Perhaps I'll get around to implementing it as soon as I
pay my taxes. :-(
But what I showed you this morning was from a program that
I just hacked from this one.
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|
|