Re: Contour Log scale

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Sat, 27 May 2006 19:40:19 -0600 (MDT)

So you want to have contour levels that are log spaced??
There have been several message to ncl-talk about this lately.

***> question and reply:
> I was wondering if there is a way to have a logarithmic colour contour axis. I
> want colour contours to go from say 0 to 30 but have a logarithmic spacing.

Yes ... You can set the contour levels explicitly.

http://www.ncl.ucar.edu/Applications/index.shtml
See "Plot Techniques" => "Contours ..."

A specific example of explicitly setting contour levels:
http://www.ncl.ucar.edu/Applications/Scripts/conLev_3.ncl

[snip]
    res@cnLevelSelectionMode = "ExplicitLevels" ; set explicit contour levels
    res@cnLevels = log10((/ 1, 3, 5, 7.5, 10, 15, 20, 25, 30/)) ; set levels
[snip]

*+*+> further

From: Marjolaine Rouault <marjolaine_at_nyahnyahspammersnyahnyah>
Date: Fri, 19 May 2006 16:11:19 +0200

Dear all,

I have actually done it using the "ExplicitLevels" contour method and
automated it like so:

maxVal is the maximum contour value

  x=ispan(1,maxVal,1)
; define levels for contouring which increase exponentially
levels = x*log(exp(x))/maxVal
; or if you want a steeper curve
levels = x^2.*log(exp(x))/(maxVal^2)

===================
Good luck

On Sat, 27 May 2006, cluo_at_uci.edu wrote:

> Yes, I want to draw the contours on ce map, but use log scale. Is it
> possible?
>
> Thanks,
>
> Chao
>
>
>>> I want to use log scale for two dimension contour plot. I have tried
>>> gsnYAxisIrregular2Log = True (or res@trYLog = True) , and
>>> plot = gsn_csm_contour_map_ce(wks_id,var(:,:),res). It dosn't work.
>> ^^^^^^^^^^^^^^^^^^^^^^
>> gsn_csm_contour_map_ce draws contours on a cylindrical equidistant (ce)
>> map.
>>
>> The aspect ratio is set by the map projection which for a global
>> map is 2-to-1.
>>
>> Did you mean gsn_csm_contour ?
>>
>>> Any help and advice appreciated!
>>
>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk_at_ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Sat May 27 2006 - 19:40:19 MDT

This archive was generated by hypermail 2.2.0 : Tue May 30 2006 - 09:35:38 MDT