| Re: Object graphics axis [message #17464 is a reply to message #17460] |
Mon, 25 October 1999 00:00  |
Ben Tupper
Messages: 186 Registered: August 1999
|
Senior Member |
|
|
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Karri Kaksonen wrote:
<blockquote TYPE=CITE>The manual says that the range of the axis is set
by a vector:
<p>[-Xmin/(Xmax-Xmin), 1/(Xmax-Xmin)]
<p>This may work if the length of the axis is 1.0 in normalized
<br>coordinates. In the course I chose the length to be 2.0 and in
<br>order to get it right I just tried out different values until
<br>I found it to be closer to:
<p>[-1-Xmin*2/(Xmax-Xmin), 2/(Xmax-Xmin)]
<p>I thought about this on my flight home last night and what I am
<br>afraid of is that the -1 in the first element may actually depend
<br>on where the axis is drawn on the screen. My location of the axis
<br>was at [-1.0, -1.0]. If this is the case then RSI should do
<br>something about it before version 5.3 comes out. Otherwise you have
<br>to update the range vector every time you reposition the axis.</blockquote>
<p><br>I've had the same difficulty... it drove me crazy for the longest
time until David F bailed me out. The weakness inherent in
RSI's formula ([-Xmin/(Xmax-Xmin), 1/(Xmax-Xmin)]) is that it assumes that
you are going to scale your data into the positional space of [0,1].
In your case, you have decided to scale into positional space of [-1, 1].
Fortunately, David F has written the NORMALIZE function for people like
me who tend to shuffle along with the lost sometimes. NORMALIZE
is available at his website. NORMALIZE accepts (as a keyword)
the POSITION you intend to scale your axis into.
<p>I was so crazed by this poblem that I wrote a tutorial for figuring
out the difference between unscaled data coordinates and scaled data coordinates.
I don't have it handy right now, but I will send it along to you as soon
as possible.
<p>Ben
<pre>--
Ben Tupper
Bigelow Laboratory for Ocean Science
tupper@seadas.bigelow.org
Pemaquid River Company
pemaquidriver@tidewater.net</pre>
</html>
|
|
|
|