<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:13px"><div class="" style="">Hi NCL User,</div><div class="" style="">I am facing big problem with GPCP daily data. I doing daily annual cycle with other CMIP5 models this work well. However, GPCP data gives following error message that I could not solve.Your kind help are appreciated</div><div class="" style=""><br class="" style=""></div><div class="" style="color: rgb(0, 0, 0); font-size: 13px; font-family: 'times new roman', 'new york', times, serif; background-color: transparent; font-style: normal;">Error are highlighted in the script below</div><div class="" style="color: rgb(0, 0, 0); font-size: 13px; font-family: 'times new roman', 'new york', times, serif; background-color: transparent; font-style: normal;"><br></div><div class="" style="color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span
 class="">*************</span><span style="font-family: Menlo; font-size: 11px;" class="">fatal:Subscript out of range, error in subscript #0</span></div>
<div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">fatal:An error occurred reading pr9Area***********</div><div class="" style="color: rgb(0, 0, 0); font-size: 13px; font-family: 'times new roman', 'new york', times, serif; background-color: transparent; font-style: normal;">Script for GPCP sub</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">j =addfile ("/Users/ahaque/Desktop/CMIP5/historical/Daily/historical/jjas_hist_50y/jjas_hist_50y/GPCP_1DD_v1.2_199610-201312_sa.nc", "r")</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp;&nbsp; pr9=j-&gt;PREC;(6301x16X21;x21;{lat1:lat2},{lon1:lon2}) &nbsp; ; (time,lat,lon)&nbsp; (0,1,2)</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp;time9 &nbsp; &nbsp; = i-&gt;time</div><div style="margin-top: 0px;
 margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">;Convert kg to mm</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; pr9&nbsp; &nbsp; &nbsp; &nbsp; = pr9*1.</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; pr9@units&nbsp; = "mm/day"</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; printVarSummary(pr9)</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; printMinMax(pr9,1)</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; clat9&nbsp; &nbsp; &nbsp; = latRegWgt(pr9&amp;lat, typeof(pr9), 0) ; create lat weights</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; pr9Area&nbsp; &nbsp; =
 wgt_areaave_Wrap(pr9, clat9, 1, 0)&nbsp; ; weighted area avg</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; ymdStrt9 &nbsp; = 199610 ; start yyyymmdd</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; ymdLast9 &nbsp; = 201312&nbsp; &nbsp; &nbsp; ;last</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; yrStrt &nbsp; &nbsp; = ymdStrt9/10000</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; yrLast &nbsp; &nbsp; = ymdLast9/10000</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; nhar &nbsp; &nbsp; &nbsp; = 4&nbsp; ; no of fourier comp</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; var&nbsp; &nbsp; &nbsp; &nbsp; =
 "pr"</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; TIME9&nbsp; &nbsp; &nbsp; = cd_calendar(time9,0) &nbsp; ; type of float</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; year9&nbsp; &nbsp; &nbsp; = floattointeger( TIME9(:,0) )</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; month9 &nbsp; &nbsp; = floattointeger( TIME9(:,1) )</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; day9 &nbsp; &nbsp; &nbsp; = floattointeger( TIME9(:,2) )</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; ddd9 &nbsp; &nbsp; &nbsp; = day_of_year(year9, month9, day9)</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; yyyyddd9 &nbsp;
 = year9*1000 + ddd9</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; nday9&nbsp; &nbsp; &nbsp; = 365</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; pday9&nbsp; &nbsp; &nbsp; = new ( nday9, typeof(pr9), getFillValue(pr9))</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; do nd9&nbsp; &nbsp; &nbsp; =0,nday9-2</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp;&nbsp; &nbsp; iday9 &nbsp; = ind(ddd9.eq.(nd9+1))</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp;&nbsp; &nbsp; <span style="background-color: rgb(253, 239, 43);">pday9(nd9) = avg(pr9Area(iday9))</span></div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;"
 class="">&nbsp;&nbsp; &nbsp; delete(iday9) &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ; may change next ireration</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp; &nbsp; end do</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp;&nbsp; pday9(nday9-1)= 0.5*(pday9(0)+pday9(nday9-2))</div><div style="background-color: transparent;" class="">





























</div><div style="margin-top: 0px; margin-bottom: 0px; font-size: 11px; font-family: Menlo;" class="">&nbsp;&nbsp; pr9AvgRegion&nbsp; = avg(pr9Area)</div><div class="" style=""><br class="" style=""></div></div></body></html>