[Thread Prev][Thread Next][Index]

Re: Contour label format

Hi Paulo,
	Here is an idea that could be of use. Its probably not new and
could certain be improved on.  It uses the ppl conpre,conpst that Billy
referred to and a version for negative powers would be easy (with
varb*`expo` and conpst,x10^-^`expo` .


First create a script contour123.jnl :

! contour125 : contours levels 1,2,5 of variable varb
!              scaled down by 10^expo
contour/over/set/nolab varb/10^`expo`
ppl conpre,@p1 ; ppl conpst,x10^`expo`
ppl lev,(),(1,1,1,-1),pen(1,1,1,7)
ppl lev,(2,5,3,-1),pen(2,5,3,1)
ppl contour/over

then apply it to a demo function as follows:

let v=3.e5/exp(((i-10)^2+(j-10)^2)/20) ; region/i=1:20/j=1:20
let varb=v
! find range (13.6 to 300000 here) and create EMPTY contour plot
list varb[i=@min,j=@min],varb[i=@max,j=@max]
contour/lev=(1) varb
! then lay on the required number of decades of 1,2,5
repeat/k=1:5 (let expo=`k` ; go contour125)

|__Room 2070 Bldg#3 NOAA/PMEL__|

[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement