<div dir="ltr"><div><div><div><div>Please, always include the version of NCL you are using.<br><br></div>%> ncl -V<br><br></div><div>Also, helpful would be to include (attach) a sample file dump:<br><br></div><div>%> ncl_filedump  CAL_LID_L2_05kmAPro-Standard-V<wbr>4-10.....hdf >! dump.CAL_LID_L2</div><div><br>===========<br><br></div>I *speculate* that the following may be the issue:<br><br>   f = addfiles(diri+fili,"r")<br><br></div>Since addfiles creates a variable (here, 'f') of type list: one loop iteration may create a list containing (say) 10 files, the next may have a list containing (say) 5 files. DIfferent sizes.<br><br>f the sizes change, you should use the NCL reassignment operator    :=<br>-----<br>By default, NCL is a <b><span class="gmail-il">strongly</span> <span class="gmail-il">typed</span> <span class="gmail-il">language</span></b>. It will not allow certain operations.<br><br>float  a(10)<br>double b(10)<br>float c(30)<br><br>By default:<br>    a = b     ; NCL will issue a FATAl error; it will not allow a double=> float<br><br>    a = c     ; FATAL ... it will not allow an array of size 30 to be reassigned to an array that is size 10<br></div>                 ; This is where the <br>                 ; "<b><span style="color:rgb(0,0,0);font-family:Menlo;font-size:11px">Dimension sizes of left hand side and right hand side of assignment do not match"</span></b><div><br>     a := b   ; OK<br>     a := c   ; OK<br><br>-----<br></div><div>Try using NCL's reassignment operator   <b>:=</b><br><br>   f <b>:=</b> addfiles(diri+fili,"r")</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Dec 28, 2017 at 2:12 AM, Shani Tiwari via ncl-talk <span dir="ltr"><<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Dear NCL users <div>                         I want to read multiple CALIPSO data files (5444 files) and add all file files in every five days average but I got the error. </div><div><b><span style="color:rgb(0,0,0);font-family:Menlo;font-size:11px">Dimension sizes of left hand side and right hand side of assignment do not match</span></b></div><div> Here is my script following the <span style="font-size:12.800000190734863px">calipso_3.ncl at <a href="https://www.ncl.ucar.edu/Applications/calipso.shtml" target="_blank">https://www.ncl.ucar.edu/Ap</a></span><span style="font-size:12.800000190734863px"><a href="https://www.ncl.ucar.edu/Applications/calipso.shtml" target="_blank"><wbr>plications/calipso.shtml</a></span>. Kindly help me to overcome this problem.  </div><div><br></div><div><div>;-----------------------------<wbr>-----------------</div><div>load "$NCARG_ROOT/lib/ncarg/nclscri<wbr>pts/csm/gsn_code.ncl"</div><div>load "$NCARG_ROOT/lib/ncarg/nclscri<wbr>pts/csm/gsn_csm.ncl"</div><div>load "$NCARG_ROOT/lib/ncarg/nclscri<wbr>pts/csm/contributed.ncl"</div><div>load "$NCARG_ROOT/lib/ncarg/nclscri<wbr>pts/csm/shea_util.ncl"</div><div>load "$NCARG_ROOT/lib/ncarg/nclscri<wbr>pts/contrib/ut_string.ncl"</div><div>;-----------------------------<wbr>-----------------</div><div>begin</div><div><br></div><div>;-----------------------------<wbr>-----------------</div><div>;  OPEN CALIPSO FILES of the selected year, month and days</div><div>;-----------------------------<wbr>-----------------</div><div>; define year, month, date (yyyys, mms, dds) as strings</div><div>;-----------------------------<wbr>-----------------</div><div> yyyys = (/"2014"/)</div><div> mms   = (/"06","07","08","09","10","11<wbr>","12"/)</div><div> dds   = (/"01","02","03","04","05","06<wbr>","07","08","09","10", \</div><div>           "11","12","13","14","15","16"<wbr>,"17","18","19","20", \</div><div><span class="m_7491492877433041976m_-6533143622812535667m_-828709180666739205m_-5279031126286715142gmail-Apple-tab-span" style="white-space:pre-wrap">              </span>   "21","22","23","24","25","26",<wbr>"27","28","29","30", "31"/)</div><div> <span class="m_7491492877433041976m_-6533143622812535667m_-828709180666739205m_-5279031126286715142gmail-Apple-tab-span" style="white-space:pre-wrap">            </span>   </div><div> ;kyy=14     ; year 20kyy</div><div>  jmm=7      ; month  jmm</div><div> </div><div>;-----------------------------<wbr>-----------------</div><div>; setting directory of the data files</div><div>;-----------------------------<wbr>-----------------</div><div>  </div><div> diri = "/Volumes/OSX/CALIPSO/L2V410/2<wbr>014/" </div><div> </div><div>;-----------------------------<wbr>-----------------</div><div>;-----------------------------<wbr>-----------------</div><div>;  LOOP TO GET FILE NAMES OF A DAY SEQUENTIALLY</div><div>;  AND READ THE FILE</div><div>;-----------------------------<wbr>-----------------<br></div><div>;-----------------------------<wbr>-----------------</div><div><br></div><div>do idd=0,5  ;30                                           ; loop for day (idd-1). </div><div> </div><div> fili = systemfunc("cd "+diri+" ; ls CAL_LID_L2_05kmAPro-Standard-V<wbr>4-10."+yyyys+"-"+mms(jmm-1)+"-<wbr>"+dds(idd)+"*N.hdf ")</div><div> nfil = dimsizes(fili)                                   ; nfil = number of CALIPSO files, use for loop.</div><div><br></div><div>;print (nfil)</div><div><br></div><div> f = addfiles(diri+fili,"r")</div><div><br></div><div><br></div><div>end do</div><div><br></div><div>;print (f)</div></div><div><br></div><div>end   </div><div><div><div class="m_7491492877433041976m_-6533143622812535667m_-828709180666739205m_-5279031126286715142gmail-m_-321231133885211943gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div><br></div><div>------------------------------<wbr>------------------------------<br></div><div dir="ltr">Shani Tiwari, Ph.D.</div><div>Graduate School of Environmental Studies, </div><div>Nagoya University, Nagoya, Japan </div><div dir="ltr"><div>Mob: <a href="tel:+91%2094519%2052997" value="+919451952997" target="_blank">+91 9451952997</a><br></div><div>Skype ID: shani.tiwari2</div><div>Research Gate: <a href="https://www.researchgate.net/profile/Shani_Tiwari2" style="color:rgb(17,85,204)" target="_blank">Dr. Shani Tiwari</a>  <br></div><div>Google Scholar Web-page: <a href="https://scholar.google.co.jp/citations?user=IjIjMTMAAAAJ&hl=en" style="color:rgb(17,85,204)" target="_blank">Dr. Shani Tiwari</a></div></div></div><div dir="ltr"><div>------------------------------<wbr>------------------------------<wbr>-</div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div>
</div></div>
<br>______________________________<wbr>_________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu">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/<wbr>mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br></div>