[ncl-talk] multiple colorbars on panel plot
Laura Fowler
laura at ucar.edu
Mon Aug 27 12:20:28 MDT 2018
Hi Adam:
Unfortunately, it did not work for me. I may have misunderstood the changes
that I needed to make. In my script, I call gsn_define_colormap before
plotting the individual plots since I have a colorbar under each individual
plot. So even when I called gsn_panel for the first 4 plots, I still get
the colorbar that I called last.
Here is the updated plot where now the 4 top plots use the one I assigned
to the difference plot. See test.ncl in /gpfs/fs1/scratch/laura/
Many thanks,
Laura
On Mon, Aug 27, 2018 at 11:58 AM, Adam Phillips <asphilli at ucar.edu> wrote:
> Hi Laura,
> Yes, you should call gsn_panel twice, drawing the first 4 plots in the
> first call and the last two plots in the second call. Something like this:
>
> ; create plots 1-4
>
> panres = True
> panres at gsnFrame = False
> panres at gsnPanelTop = .95
> panres at gsnPanelBottom = .35
> gsn_panel(wks,plot(:3),(/2,2/),panres)
>
> ; switch colormap and create plots 5-6
>
> panres at gsnPanelTop = .35
> panres at gsnPanelBottom = .05
> gsn_panel(wks,plot(4:),(/1,2/),panres)
> frame(wks)
>
> The gsnPanelTop/gsnPanelBottom settings for each gsn_panel call might have
> to be adjusted.
> Hope that helps, if you have further questions let ncl-talk know.
> Adam
>
> On Mon, Aug 27, 2018 at 11:49 AM Laura Fowler <laura at ucar.edu> wrote:
>
>> Hello:
>>
>> I am attaching a plot that shows 6 different plots in one panel plot. The
>> two bottom plots e) and f) are differences of the two plots above them. The
>> plots a) b), c), and d) use my user define colorbar.
>>
>> Is there a way to use the colorbar precip_diff_12lev instead of my own
>> colorbar for the bottom 2 plots so that I can have white in the middle
>> since it is a different plot while using my own colorbar for the top 4
>> plots? When I redefine gsn_colormap before plotting the last 2 plots, then
>> all 6 plots use colorbar precip_diff_12lev? I put my ncl script in
>> /gpfs/fs1/scratch/laura/panel.dqvcup.ncl in case one wants to take a
>> pick?
>>
>>
>> Thanks,
>> Laura
>>
>>
>>
>> --
>> !-----------------------------------------------------------
>> --------------------------------------------------
>> Laura D. Fowler
>>
>> Mesoscale and Microscale Meteorology Division (MMM)
>> National Center for Atmospheric Research
>> P.O. Box 3000, Boulder CO 80307-3000
>>
>> e-mail: laura at ucar.edu
>> phone: 303-497-1628
>>
>> !-----------------------------------------------------------
>> --------------------------------------------------
>> _______________________________________________
>> ncl-talk mailing list
>> ncl-talk at ucar.edu
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>
>
> --
> Adam Phillips
> Associate Scientist, Climate and Global Dynamics Laboratory, NCAR
> www.cgd.ucar.edu/staff/asphilli/ 303-497-1726
>
> <http://www.cgd.ucar.edu/staff/asphilli>
>
--
!-------------------------------------------------------------------------------------------------------------
Laura D. Fowler
Mesoscale and Microscale Meteorology Division (MMM)
National Center for Atmospheric Research
P.O. Box 3000, Boulder CO 80307-3000
e-mail: laura at ucar.edu
phone: 303-497-1628
!-------------------------------------------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20180827/785ab8af/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.png
Type: image/png
Size: 167104 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20180827/785ab8af/attachment.png>
More information about the ncl-talk
mailing list