; ; This program reads in the stratus retrieval into the variables: ; base_time,time_offset,height,nmean,lwc,re,tau ; pro simple_get_stret ;filedir='/data/mace2/arm_data/nsa/DnsastretC1.Dong/' filedir='/home/tgarrett/ARCTIC/Dong2000/' filestring='DnsastretC1.Mace*Dong_flux.cdf' files=findfile(filedir+filestring,count=num_files) for i=0,num_files-1 do begin ; ; Name of the data file ; ;filename='/data/mace2/arm_data/nsa/DnsastretC1.Dong/DnsastretC1.Mace.20000930.000000.Dong_flux.cdf' ; ; Open the netcdf file ; print,files[i] cdfid=ncdf_open(files[i]) ; ; Get the variable id's ; ;base_time_id=ncdf_varid(cdfid,'base_time') ;time_offset_id=ncdf_varid(cdfid,'time_offset') ;height_id=ncdf_varid(cdfid,'height') ;nmean_id=ncdf_varid(cdfid,'N_mean') ;lwc_id=ncdf_varid(cdfid,'lwc') ;re_id=ncdf_varid(cdfid,'re') ;tau_id=ncdf_varid(cdfid,'tau') re_dong_id=ncdf_varid(cdfid,'re_dong') status_id=ncdf_varid(cdfid,'status') ; ; Get the variables ; ;ncdf_varget, cdfid, base_time_id, base_time ;ncdf_varget, cdfid, time_offset_id, time_offset ;ncdf_varget, cdfid, height_id, height ;ncdf_varget, cdfid, nmean_id, nmean ;ncdf_varget, cdfid, lwc_id, lwc ;ncdf_varget, cdfid, re_id, re ;ncdf_varget, cdfid, tau_id, tau ncdf_varget, cdfid, re_dong_id,re_dong ncdf_varget, cdfid, status_id,status ; ; Close the netcdf file ; ncdf_close,cdfid if i eq 0 then begin com_re_dong=re_dong com_status=status endif else if i gt 0 then begin com_re_dong=[com_re_dong,re_dong] com_status=[com_status,status] endif endfor result=where(com_re_dong gt 0 and com_status eq 1,count) com_re_dong=com_re_dong[result] re_dong=make_array(n_elements(com_re_dong)-1) for i=0,n_elements(com_re_dong)-13,12 do begin re_dong[i]=mean(com_re_dong[i:i+12]) endfor window,0;,/pixmap loadct,0 !p.charsize=1.5 !p.background=!d.n_colors-1 plot,re_dong,yrange=[0,max(re_dong)],color=0,psym=2,$ ytitle='re_dong microns',xtitle='time' write_gif,'re_dong_timeseries.gif',tvrd() stop return end