[gradsusr] extracting variables from diferent model runs

kombo kai kaikombo at yahoo.com
Fri Jul 3 08:49:07 EDT 2015


Hi grads usersI have a nc file having four variables (msl, temperature at 2m, dewpoint at 2m and total cloud cover) with for different model runs (i.e. 06,12,and 18).I want to get the filesforI want either toget the separate file for each variable and foe each model run  or separate files for having all variables for each model runMy nspection shows that  model run for 06 is given by the time steps of 1,5,9,13,..............4*t-3for 12 the time steps are given by 2,6,10,14,18,.........4*t-2for 18 the time steps are given by 3,7,11,15,19........4*t-1where as that of 00 is given by 4,8,12,16,........4*tI have tried to develop a script to separate each variable in each model run

My script reads like 
reinit'sdfopen E:/ECMWF_Data/EC_data/ecmwf_4ense-inst-msl_tcc_t2m06.nc''set grid off''set grads off''set x 1 105''set y 1 105''set lon 28 41''set lat -13 0't =1while (t<=395)   'define 06t2m=t2m'   'set sdfwrite E:/ECMWF_Data/EC_data/ecmwf_06t2mnew.nc'   'sdfwrite 06t2m'   t =4*t-3endwhile"C'when I run this script it takes long time with out wring the fileI wantwhen I endt with t=t+4 it write the file with only one time stepI their any one to help this?either to write all variables in at one model run, so that I can have for separate files or to write each variable in a single model run so I can have sixteen filesregardskaikombo

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20150703/914dc01a/attachment.html 


More information about the gradsusr mailing list