<div dir="ltr">Hi,<div> when I use below code, I found the return yyyy is wrong. the time value is 1, 2, 3... its unit is month since 2006-01, but the return value from cd_calendar is 200602, not 200601. Please check cd_calendar function. </div><div><br></div><div>Best,</div><div>Yongli</div><div><br></div><div>
f=addfile("rcp45/BCC-CSM1.1/tas_Amon_bcc-csm1-1_rcp45_r1i1p1_200601_210012.nc","r")<br>time=f->time</div><div>yyyy=cd_calendar(time,-1)<br>print(yyyy(0:13))<br><br>====================<br>Variable: yyyy (subsection)<br><br>Type: integer<br>Total Size: 56 bytes<br> 14 values<br>Number of Dimensions: 1<br>Dimensions and sizes: [14]<br>Coordinates: <br>Number Of Attributes: 1<br> calendar : noleap<br>(0) 200602<br>(1) 200603<br>(2) 200604<br>(3) 200605<br>(4) 200606<br>(5) 200607<br>(6) 200608<br>(7) 200609<br>(8) 200610<br>(9) 200611<br>(10) 200612<br>(11) 200701<br>(12) 200702<br>(13) 200703<br></div><div><br></div>the time variable in file is as below:<div><br>float time ( time )<br> units : month since 2006-01<br> calendar : noleap<br> axis : T<br> long_name : time<br> standard_name : time</div></div>