;+
; Contains the build_directory function
;
; :Author:
; Gaƫlle Boisnard
;
; :History:
; 2005/10/05: Created
;
; 2005/10/05: Last Edit
;-
;
;+
; build_directory is a function that <behavior desc here>
;
; :Returns:
; <return desc here>
;
; :Params:
; yyyydddhh: in, required, type=sometype
; A parameter named yyyydddhh
;-
function build_directory, yyyydddhh
yearl=yyyydddhh/100000
year=strmid(string(yearl), 0, 4)
day=long(strtrim(strmid(string((yyyydddhh-yearl*100000)/100), 4, 3), 2))
case 1 of
day ge 1 and day le 90: dir=year+'_001_090'
day ge 81 and day le 180: dir=year+'_091_180'
day ge 181 and day le 270: dir=year+'_181_270'
day ge 271 and day le 366: dir=year+'_271_366'
endcase
return, dir
end