; Use this main program as an example of how to call the get_scat_averaged_v4 reading routine ; enter julian day and long year (day and year shown here match the verification file data) for lyear=2000,2000 do begin ;qscat verify 2000,2000 : seawinds verify 2003,2003 for jday=11,11 do begin ;qscat verify 11,11 : seawinds verify 115,115 jul2day, jday,lyear, month,dayofmonth ; jul2day subroutine is from the Earth Space Research Group, UCSB, IDL library available online yy=string(lyear,format='(i4.4)') mm=string(month,format='(i2.2)') dd=string(dayofmonth,format='(i2.2)') for itype=0,2 do begin ; read three types of time_averaged data (3-day, week and month) ; create file name of data file to read case itype of 0: BEGIN ;3-day file_path='' ;file_path='drive:\provide your own file path\' filename=file_path+'qscat_'+yy+mm+dd+'v4_3day.gz' print,filename END 1: BEGIN ;week wkend='26' ;this is hard coded to Jan 15th for the qscat verification file, Apr 26th for seawinds verification file file_path='' ;file_path='drive:\provide your own file path\' filename=file_path+'qscat_'+yy+mm+wkend+'v4.gz' print,filename END 2: BEGIN ;month file_path='' ;file_path='drive:\provide your own file path\' filename=file_path+'qscat_'+yy+mm+'v4.gz' print,filename END endcase ; read scatterometer data Get_scat_averaged_v4,filename, windspd,winddir,scatflag,radrain,ierr if(ierr eq 1) then goto, nofile good=where(windspd le 50.0, cntgood) if (cntgood eq 0) then goto, nofile ; write out data in verification file for ilat=273,277 do begin ;for qscat and seawinds verification 273,277 for ilon=169,174 do begin ;for qscat and seawinds verification 169,174 print,ilon+1,ilat+1,$ windspd[ilon,ilat],winddir[ilon,ilat],$ scatflag[ilon,ilat],radrain[ilon,ilat],$ format='(2i6,2f9.2,i5,f12.2)' endfor ;ilon endfor ;ilat nofile: if(cntgood eq 0) then print,'file not found: ', filename endfor ;file type endfor ;jday endfor ;lyear end