Re: Philosophical Scaling Question [message #51595 is a reply to message #51593] |
Mon, 04 December 2006 10:00   |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Brian Larsen writes:
> I think I agree with this statement but for most all of (making an
> assumption there I guess) just having it plot in decades as opposed to
> linear is good enough. In that case I think this thread may have
> solved this.
>
> maybe give the user some options to pass onto logscl but have the
> defaults just as were used here...
Well, *exactly*. I've thought all along the request
for a "logarithmic color bar" didn't make much sense.
Because if this is all you want, COLORBAR already does
this.
LoadCT, 33
image = LoadData(7)
TVLCT, r, g, b, /GET
data = Scale_Vector(image, 1, 1000) ; Data in log scale.
pos = [0.1, 0.1, 0.9, 0.7]
TVImage, LogScl(data), Position=pos, /Keep, /Erase
index = Bindgen(256)
TVLCT, r[LogScl(index)], g[LogScl(index)], b[LogScl(index)]
Colorbar, Range=[1,1000], XLOG=1, Divisions=3, $
Position=[pos[0], 0.87, pos[2], 0.93], Minor=5
You can choose the logarithmic scale to use. Use LOGSCL
for a true log scaling. Choose GMASCL for a power-law
scaling. Or, even choose an inverse hyperbolic sine scaling
with with ASINHSCL:
http://www.dfanning.com/ip_tips/xstretch.html
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|