Sorry for the confusion. The trick with the cgcontour solved my problem.
When i told you about
cgImage, data, /axis, xabscissa=x, yabscissa=y
meaning that the result would work for both uniform and non uniform x and y, without getting into more trouble, as the
cgcontour, data, x,y
does already
Of course
cgImage, data, /axis, xr=[min(x),max(x)], yr=[min(y),max(y)]
and
cgImage, data, /axis, xabscissa=x, yabscissa=y
would be equivalent only for uniform grid!
Now in terms of the keystrokes, the in uniform grid, i think
cgImage, data, /axis, xa=x, ya=y
is better than
cgImage, data, /axis, xr=[min(x),max(x)], yr=[min(y),max(y)]
And in the non uniform grid
cgImage, data, /axis, xa=x, ya=y
is better than
cgContour, data, /nodata, /noerase, OPosition=opos
cgImage, image, OPOSITION=opos, /noerase,/over
cgContour, data, /nodata, /noerase, Position=opos
Both are more simple and more intuitive. At least for me!
From your amazing work concerning usability and simplicity in idl graphics, I assume that a fan of simplicity such as yourself would like to get new ideas on how to improve the usability of his software!
Cheers,
Petros
On Friday, March 28, 2014 7:28:01 PM UTC, David Fanning wrote:
> Petros Syntelis writes:
>
>
>
>>
>
>> Thanks for the quick reply David.
>
>>
>
>> I was thinking more something like this:
>
>> Assume we have, x,y and data.
>
>> if we use
>
>> cgContour, data, x,y
>
>> we will get a plot with axis having the values of x,y
>
>>
>
>> In cgImage, i was thinking like
>
>> cgImage, data, /axis, xabscissa=x, yabscissa=y
>
>>
>
>> That would produce a similar result.
>
>> If somebody wants to plot many images with values on axis, this would be much faster and easier than
>
>> cgImage, data, /axis, xr=[min(x),max(x)], yr=[min(y),max(y)]
>
>
>
> OK, now you have confused me. :-)
>
>
>
> I thought you were looking for non-linear labeling of the axes. How does
>
> this suggestion produce non-linear axis labeling?
>
>
>
> Are you just looking to save a few keystrokes? In other words, are you
>
> asking if I can let cgImage calculate the xrange from an X vector, and
>
> so forth? I suppose I could. If you put some cash into the Coyote Store,
>
> I suppose I might even want to. ;-)
>
>
>
> Cheers,
>
>
>
> David
>
> --
>
> David Fanning, Ph.D.
>
> Fanning Software Consulting, Inc.
>
> Coyote's Guide to IDL Programming: http://www.idlcoyote.com/
>
> Sepore ma de ni thue. ("Perhaps thou speakest truth.")
|