;+ ; ; .. _TropFlux_swr_BLND_19890101_20091231.pro: ; ; ======================================= ; TropFlux_swr_BLND_19890101_20091231.pro ; ======================================= ; ; .. graphviz:: ; ; digraph TropFlux_swr_BLND_19890101_20091231 { ; graph [ ; rankdir="LR", ; ] ; file_dt [shape=ellipse,fontname=Courier,label="/Users/pkb/data/TropFlux/TropFlux_swr_19890101_20071231_DT_v50.nc"]; ; file_nrt [shape=ellipse,fontname=Courier,label="/Users/pkb/data/TropFlux/TropFlux_swr_19890101_20091231_NRT_v50.nc"]; ; file_gustiness [shape=ellipse,fontname=Courier,label="/Users/pkb/data/TropFlux/TropFlux_gustiness_19890101_20091231_v50.nc"]; ; ; ncfile [shape=ellipse,fontname=Courier,label="/Users/pkb/data/TropFlux/TropFlux_swr_19890101_20091231_BLND.nc"]; ; ; TropFlux_swr_BLND_19890101_20091231 [shape=box, ; fontname=Courier, ; color=blue, ; URL="http://forge.ipsl.jussieu.fr/tropflux/browser/trunk/src/TropFlux_swr_BLND_19890101_20091231.pro", ; label="${PROJECT}/src/TropFlux_swr_BLND_19890101_20091231.pro"]; ; {file_dt file_nrt file_gustiness} -> {TropFlux_swr_BLND_19890101_20091231} ->{ ncfile} ; ; } ; ; SEE ALSO ; ======== ; ; :func:`initncdf ` ; :func:`read_ncdf ` ; :func:`julday ` ; :func:`ncdf_quickwrite ` ; ; EXAMPLES ; ======== ; ; :: ; ; IDL> tropflux_swr_blnd_19890101_20091231 ; ; ; TODO ; ==== ; ; hard coded directory - usage of ${PROJECT_ID} ; ; coding rules ; ; EVOLUTIONS ; ========== ; ; - fplod 20101215T085754Z aedon.locean-ipsl.upmc.fr (Darwin) ; ; * add graph in header ; ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) ; ; * minimal header ; ; - pbk 2008 ; ; * creation ; ;- pro TropFlux_swr_BLND_19890101_20091231 @common dir="/Users/pkb/data/TropFlux/" file=dir+"TropFlux_swr_19890101_20071231_DT_v50.nc" initncdf, file dt=read_ncdf("swr", 19890101, 20071231, file=file,/nostr) help, dt file=dir+"TropFlux_swr_19890101_20091231_NRT_v50.nc" initncdf, file nrt=read_ncdf("sw", 20080100, 20100112, file=file,/nostr) help, nrt swr_nrt=read_ncdf("sw", 19880101, 20100112, file=file,/nostr) swr_dt=[[[dt]],[[nrt]]] help, swr_dt, swr_nrt swr_merged=swr_dt*0. time=timegen(7670, units='days', start=julday(1,1,1989,0)) & jpt=n_elements(time) a=interpol([1.,0.],[julday(10,01,2007),julday(12,31,2007)],time) a=((a > 0.) < 1.) for jt=0,jpt-1 do swr_merged(*,*,jt)=swr_dt(*,*,jt)*a(jt)+(1-a(jt))*swr_nrt(*,*,jt) file=dir+"TropFlux_gustiness_19890101_20091231_v50.nc" initncdf, file time=timegen(7670, units='days', start=julday(1,1,1989,0)) & jpt=n_elements(time) lat=reform(gphit(0,0:jpj-1)) lon=reform(glamt(0:jpi-1,0)) cda0=string(jul2date(time(0)),format='(i8.8)') cda1=string(jul2date(time(jpt-1)),format='(i8.8)') time=time-julday(1,1,1950,00,00) ncfile='!/Users/pkb/data/TropFlux/TropFlux_swr_19890101_20091231_BLND.nc lon_attr={units:'degrees_east',long_name:'Longitude'} lat_attr={units:'degrees_north',long_name:'Latitude'} time_attr={units:'days since 1950-01-01 00:00:00',long_name:'Time axis',time_origin:'1950-JAN-01 00:00:00'} sw_attr={units:'w/m^2',missing_value:1.e20,long_name:'Net Shortwave Radiation',short_name:'swr',axis:'TYX'} globattr={source:'ISCCP based SWR until 2007, after 2007 timeseries is completed with OLR based SWR. A linear transition is applied from ISCCP based SWR to OLR based SWR'} ncfields = 'swr[longitude,latitude,time]=swr_merged:sw_attr; ' $ + 'longitude[]=lon:lon_attr; ' $ + 'latitude[]=lat:lat_attr; ' $ + 'time[*time]=time:time_attr ' $ + ' @ globattr' @ncdf_quickwrite end