<div dir="ltr">Hi Adam,<div><br></div><div>thanks for your suggestion, however setting the opacity of the chla_plot to semi-transparent did not solve the problem. In fact I should see both fields without setting the opacity to semi-transparent as buff1 is slightly larger than chla. <br></div><div><br>In any case, I realized that I do not need the &#39;overlay&#39; procedure after all, because I will have to use only one field for my mask which simply takes on different values for different lat-lon regions.<br><br></div><div>thanks again,<br></div><div>Anne<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 30 May 2017 at 20:39, Adam Phillips <span dir="ltr">&lt;<a href="mailto:asphilli@ucar.edu" target="_blank">asphilli@ucar.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Anne,<div>Without being able to run your script from here, my best guess on your issue is that you are overlaying a color-filled contour field on a 2nd color-filled contour field. I would try setting the opacity of the your chla_plot to be semi-transparent. Add this line to your res2 resource list.</div><div><div>res2@cnFillOpacityF = 0.5<br></div><div><br></div></div><div>The resulting plot should show both your chla and buff plots. More information about the various opacity resources can be found here:</div><div><a href="http://www.ncl.ucar.edu/Applications/rgbacolor.shtml" target="_blank">http://www.ncl.ucar.edu/<wbr>Applications/rgbacolor.shtml</a><br></div><div><br></div><div>Other minor things that I see:</div><div>- You do not need to set sfXArray or sfYArray as your chla and buff arrays have attached latitude/longitude coordinate variables. You also do not need to set those resources in your mpres resource list as they are not needed when using gsn_csm_map.</div><div>- I do not think you need to set res@cnFillDrawOrder.</div><div>- You create a mpres resource list, and then create a res and a res2 resource list from mpres, and that carries your map resource settings through to res and res2. I think simply deleting this line: res = mpres   will get rid of many (if not all) of your error messages. </div><div><br></div><div>If that above does not solve your plotting issue please respond to the ncl-talk email list.</div><div>Adam</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Mon, May 29, 2017 at 3:47 AM, Anne <span dir="ltr">&lt;<a href="mailto:anne.seidenglanz@unive.it" target="_blank">anne.seidenglanz@unive.it</a>&gt;</span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr">Hi everybody,<div><br></div><div>I have a problem overlay-ing two contour fields on a map plot (see script attached). The final purpose is to mask out a specified area on a global triangular grid (simply consisting of ones and zeros), and to create a buffer zone around the area for physical reasons. Creating the mask itself is no problem, but when I want to overlay the layers for creating the buffer zone (for which each layer is just slightly bigger than the following one), NCL just plots me the last overlaid field. So when I do (here an example of 2 contour fields on top of each other):</div><div><br></div><div><div>    map_plot  =  gsn_csm_map(wks, mpres)<br></div><div>    chla_plot =  gsn_csm_contour(wks, chla, res2)</div><div>    buff_plot = gsn_csm_contour(wks, buff, res)</div></div><div><br></div><div>    overlay(map_plot, buff_plot)<br></div><div><div>    overlay(map_plot, chla_plot)</div></div><div><br></div><div>then only &#39;chla_plot&#39; is successfully overlaid on the map plot, but not &#39;buff_plot&#39; (which is bigger in spatial extent than &#39;chla&#39;). There are some error messages regarding resources that cannot be used but because I can successfully plot each field on top of the map plot separately (apart from the red line when plotting &#39;buff&#39;), I assume they are not important. </div><div><br></div><div>A few things to note:</div><div>0) Both chla and buff have associated coordinate arrays. </div><div>1)  gsn_csm_contour_map_overlay did not work either, it plots only &#39;chla&#39; and some strange contour labels for &#39;buff&#39;, but distorted.</div><div>2)  switching off the satellite projection did not make any difference</div><div>3)  I can plot each field (&#39;chla&#39; and &#39;buff&#39;) separately overlaid on the map successfully </div><div>4)  I have also tried to use gsn_csm_contour_map but because I can use this only as my base plot, the overlaid contours (chla and buff) look disorted using gsn_csm_contour.</div><div><br></div><div>Anybody any idea? Any help is appreciated!</div><div><br></div><div>Thanks,</div><div>Anne    </div><div><br></div><div><br></div><div><br></div></div>

<br>
</div></div><div><font style="font-family:Arial,Helvetica,sans-serif" size="2">&quot;Nota automatica aggiunta dal sistema di posta.</font></div><div><img src="http://www.unive.it/media/BannerCalce082.jpg"></div><div><span style="font-size:small">Please note that the above message is addressed only to individuals filing Italian income tax returns.&quot;</span></div><br>______________________________<wbr>_________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailma<wbr>n/listinfo/ncl-talk</a><br>
<br></blockquote></div><span class="HOEnZb"><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div class="m_-7895335203242606050gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div><div><span><font color="#888888">Adam Phillips <br></font></span></div><span><font color="#888888">Associate Scientist,  </font></span><span><font color="#888888">Climate and Global Dynamics Laboratory, NCAR<br></font></span></div></div><div><span><font color="#888888"><a href="http://www.cgd.ucar.edu/staff/asphilli/" target="_blank">www.cgd.ucar.edu/staff/<wbr>asphilli/</a>   </font></span><span><font color="#888888"><a href="tel:(303)%20497-1726" value="+13034971726" target="_blank">303-497-1726</a> </font></span></div><span><font color="#888888"></font></span><div><div><span><font color="#888888"><br></font></span><div><span><font color="#888888"><a href="http://www.cgd.ucar.edu/staff/asphilli" target="_blank"></a></font></span></div></div></div></div></div></div></div></div></div></div></div>
</font></span></div>
</blockquote></div><br></div>

<br>
<div><font style="font-family:Arial,Helvetica,sans-serif" size="2">&quot;Nota automatica aggiunta dal sistema di posta.</font></div><div><img src="http://www.unive.it/media/BannerCalce082.jpg"></div><div><span style="font-size:small">Please note that the above message is addressed only to individuals filing Italian income tax returns.&quot;</span></div>