<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;background-color:#FFFFFF;font-family:Calibri,Arial,Helvetica,sans-serif;">
<p><br>
</p>
<br>
<div style="color: rgb(26, 26, 26);">
<div id="divRplyFwdMsg" dir="ltr"></div>
<div>
<div id="divtagdefaultwrapper" style="font-size:12pt; color:#000000; background-color:#FFFFFF; font-family:Calibri,Arial,Helvetica,sans-serif">
<p>Dear NCL gurus,</p>
<p><br>
</p>
<p>I've used NCL for more than a year, but this problem seems to be particularly tough to solve, so I think I need to refer to you.<br>
</p>
<p><br>
</p>
<p>I've been working on a script for days, I've turned it in different ways (array of data, overlay, using a single y-axis, etc...), but I can't seem to find the solution. I had a script to plot several lines on the same graph, but these lines had exactly the
 same x-axis. That was working fine. Now I'm trying to plot several profiles, that all have different x and y values, but I always receive the following error (after a bunch of warnings due to the fact that I'm plotting several types of plots with the same
 script):</p>
<p><br>
</p>
<p>warning:MainTitle is not a valid resource in plot_theta_hor_ave_fct_time_and_z_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_contour at this time<br>
warning:MainTitle is not a valid resource in plot_temp_hor_ave_fct_time_and_z_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_contour at this time<br>
warning:MainTitle is not a valid resource in plot_eth_hor_ave_fct_time_and_z_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_contour at this time<br>
warning:cnFillOn is not a valid resource in plot_T500_hor_ave_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_xy at this time<br>
warning:gsnSpreadColors is not a valid resource in plot_T500_hor_ave_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_xy at this time<br>
warning:cnLineLabelsOn is not a valid resource in plot_T500_hor_ave_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_xy at this time<br>
warning:cnLevelSelectionMode is not a valid resource in plot_T500_hor_ave_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_xy at this time<br>
warning:MainTitle is not a valid resource in plot_T500_hor_ave_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1_xy at this time</p>
<p><br>
fatal:[&quot;NclAtt.c&quot;:262]:Attribute assignment type mismatch.<br>
<br>
fatal:[&quot;Execute.c&quot;:8575]:Execute: Error occurred at or near line 589 in file plot_temperature.ncl</p>
<p><br>
</p>
<p><br>
</p>
<p>I attach the whole script if needed (plot_temperature.ncl), but here is the relevant part (the error I receive refering to line res@xyLineThicknesses = (/8.0,8.0,8.0/) ):</p>
<p><br>
</p>
<p>&quot;</p>
<p>; PLOT NUMBER 11<br>
;&nbsp; type@wkPaperSize = &quot;A4&quot;<br>
&nbsp; wks = gsn_open_wks(type,&quot;plot_prof_theta_ALL_0130_3D_No_strong_nudg_CONTROL_ALL90d_v1&quot;)&nbsp;&nbsp; ; Create a plot workstation &#43; TITLE OF THE FILE TO SAVE<br>
&nbsp; opts = True<br>
&nbsp; res = opts<br>
&nbsp; res@lbOrientation&nbsp;&nbsp; = &quot;Vertical&quot;<br>
&nbsp; res@gsnMaximize = True<br>
&nbsp; res@tmXTOn&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = False<br>
<br>
&nbsp; res@pmLegendDisplayMode = &quot;Always&quot;<br>
&nbsp; res@pmLegendSide = &quot;Top&quot;<br>
&nbsp; res@pmLegendOrthogonalPosF = -0.58&nbsp; ;-0.02 (too high), 0.15 the same, -0.15 half box is too high<br>
&nbsp; res@pmLegendParallelPosF = .67&nbsp;&nbsp;&nbsp;&nbsp; ; 0.2 is very good<br>
&nbsp; res@pmLegendWidthF = 0.0375<br>
&nbsp; res@pmLegendHeightF = 0.28<br>
&nbsp; res@lgLabelFontHeightF = 0.02<br>
&nbsp; res@xyExplicitLegendLabels = (/legend_theta(0), legend_theta(1), legend_theta(2)/)<br>
<br>
&nbsp; res@xyLineThicknesses = (/8.0,8.0,8.0/)<br>
&nbsp; res@xyLineColor&nbsp;&nbsp;&nbsp; =&nbsp; (/&quot;cyan&quot;,&quot;blue&quot;,&quot;green&quot;/)<br>
&nbsp; res@xyDashPatterns&nbsp;&nbsp;&nbsp; = (/0,0,0/)<br>
&nbsp; res@trXMinF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 200.<br>
&nbsp; res@trXMaxF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 800.<br>
&nbsp; res@trYMinF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 0.<br>
&nbsp; res@trYMaxF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =&nbsp; 30.&nbsp;&nbsp; ;30000<br>
&nbsp; res@tiXAxisString = &quot;Pot. temp (K)&quot;<br>
&nbsp; res@tiYAxisString = &quot;z (km)&quot;<br>
&nbsp; res@tiMainString = &quot;Pot. Temp. profiles&quot;<br>
<br>
&nbsp; plot&nbsp; = gsn_csm_xy(wks,array_of_theta_prof,array_of_heights,res)<br>
<br>
</p>
<p>&quot;<br>
</p>
<p><br>
</p>
<p>The netcdf files I'm using are just standard WRF output from an idealized quarter_ss type simulation. They are big files (~30GB) so I'd rather not add them now. If necessary, I'll put a few of them online.</p>
<p><br>
NOTE: If you wish to try the script on a smaller number of wrfout files, just change the num_day_max variable to a small number (I receive the same error in any case). If you don't use 90 files (as the target is), then some of the profiles in array_of_heights
 and array_of_theta_prof may be undefined. But I have checked that this is not the reason for my issue, as I get the same errors when running on the full 90 files. To avoid this slight issue, you may run the cleaned version: plot_temperature_cleaned.ncl<br>
</p>
<p><br>
</p>
<p>For information, I'm using NCL v6.3.0.</p>
<p>And &quot;uname -a&quot; returns: Linux monsoon.ccrc.unsw.edu.au 2.6.32-573.8.1.el6.x86_64 #1 SMP Tue Nov 10 18:01:38 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux<br>
</p>
<p><br>
</p>
<p>Thank you very much for your assistance.</p>
<p><br>
</p>
<p>Maxime.<br>
</p>
</div>
</div>
</div>
</div>
</body>
</html>