<div dir="ltr"><div><div><div>Hi Xin,<br></div>I think you want to change these two lines:<br>footavg@south_north=lat1d<br>footavg@west_east=lon1d<br></div><div>to this:<br>footavg&amp;south_north=lat1d<br>footavg&amp;west_east=lon1d<br><br></div><div>The former coding assigns lat1d/lon1d as attribute arrays to footavg. (Not what you want in this case.) The latter coding assigns coordinate variables to the south_north and west_east dimensions of footavg.<br><br></div><div>Hope that helps. If not, please respond to the ncl-talk list.<br>Adam <br></div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Sep 15, 2014 at 1:03 PM, Xin Xi <span dir="ltr">&lt;<a href="mailto:xin.xi30@gmail.com" target="_blank">xin.xi30@gmail.com</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"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,0)"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,0)">Hi, I am having a problem with assigning coordinate. Please tell me what I did wrong. Thanks!<br><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,0)">Part of the script:<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;color:rgb(0,0,0)">  lat1d = fspan(lat_ll,lat_ll+lat_res*(numpix_y-1),numpix_y)<br>  lat1d!0     = &quot;south_north&quot;<br>  lat1d@units = &quot;degrees_north&quot;<br>  lon1d = fspan(lon_ll,lon_ll+lon_res*(numpix_x-1),numpix_x)<br>  lon1d!0     = &quot;west_east&quot;<br>  lon1d@units = &quot;degrees_east&quot;<br><br>  footavg=dim_avg_n(foot,0) ; foot has dims of (ntime, numpix_x, numpix_y)<br>  footavg!0=&quot;south_north&quot;<br>  footavg!1=&quot;west_east&quot; <br>  footavg@south_north=lat1d<br>  footavg@west_east=lon1d<br><br>  plot = gsn_csm_contour_map(wks,footavg,res)<br><br><br></div>I GOT THIS ERROR:<br>(0)   
 check_for_y_lat_coord: Warning: Data either does not contain a valid 
latitude coordinate array or doesn&#39;t contain one at all.<br>(0)    A valid latitude coordinate array should have a &#39;units&#39; attribute equal to one of the following values: <br>(0)   
     &#39;degrees_north&#39; &#39;degrees-north&#39; &#39;degree_north&#39; &#39;degrees north&#39; 
&#39;degrees_N&#39; &#39;Degrees_north&#39; &#39;degree_N&#39; &#39;degreeN&#39; &#39;degreesN&#39; &#39;deg north&#39;<br>(0)   
 check_for_lon_coord: Warning: Data either does not contain a valid 
longitude coordinate array or doesn&#39;t contain one at all.<br>(0)    A valid longitude coordinate array should have a &#39;units&#39; attribute equal to one of the following values: <br>(0)   
     &#39;degrees_east&#39; &#39;degrees-east&#39; &#39;degree_east&#39; &#39;degrees east&#39; 
&#39;degrees_E&#39; &#39;Degrees_east&#39; &#39;degree_E&#39; &#39;degreeE&#39; &#39;degreesE&#39; &#39;deg east&#39;<br>Segmentation fault: 11</div></div>
<br>_______________________________________________<br>
ncl-talk mailing list<br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br><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 Division, 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/asphilli/</a>   </font></span><span><font color="#888888">303-497-1726 </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>