pro get_fluxes, fname common fluxes, hrfrac,jday,height,sfd,sfu,ifu,ifd,TOA_sfu,TOA_sfd,TOA_ifu cdfid=ncdf_open(fname) ; open the netcdf file time_did=ncdf_dimid(cdfid,'time') height_did=ncdf_dimid(cdfid,'height') ncdf_diminq, cdfid, time_did, char_strng, num_times ncdf_diminq, cdfid, height_did, char_strng, num_heights ; get the id's of the variables to be read num_sec_id=ncdf_varid(cdfid,'base_time') time_offset_id=ncdf_varid(cdfid,'time_offset') height_id=ncdf_varid(cdfid,'height') sfd_id=ncdf_varid(cdfid,'solar_flux_down') sfu_id=ncdf_varid(cdfid,'solar_flux_up') ifu_id=ncdf_varid(cdfid,'IR_flux_up') ifd_id=ncdf_varid(cdfid,'IR_flux_down') tsfu_id=ncdf_varid(cdfid,'TOA_solar_up') tsfd_id=ncdf_varid(cdfid,'TOA_solar_down') tifu_id=ncdf_varid(cdfid,'TOA_IR_up') ; get the data ncdf_varget, cdfid, num_sec_id, num_sec ncdf_varget, cdfid, time_offset_id, time_offset ncdf_varget, cdfid, height_id, height ijday_ihrfrac_fm_numsec, num_sec, time_offset, hrfrac, jday, yy, mm, dd, hh, mi, ss ncdf_varget, cdfid, sfd_id, sfd ncdf_varget, cdfid, sfu_id, sfu ncdf_varget, cdfid, ifu_id, ifu ncdf_varget, cdfid, ifd_id, ifd ncdf_varget, cdfid, tsfu_id, TOA_sfu ncdf_varget, cdfid, tsfd_id, TOA_sfd ncdf_varget, cdfid, tifu_id, TOA_ifu ncdf_close, cdfid return end