Blame view

src/idl/dustem_read_pol.pro 533 Bytes
427f1205   Jean-Michel Glorian   version 4.2 merged
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
;VG
FUNCTION dustem_read_pol,dir_in,file,silent=silent

st=''
Nmax=10000L
sts=strarr(Nmax)
openr,unit,dir_in+'data/'+file,/get_lun

;==read comments
str='' & first_char='#'
WHILE first_char EQ '#' DO BEGIN
  readf,unit,str
  first_char=strmid(str,0,1)
ENDWHILE

stv=str_sep(strtrim(strcompress(str),2),' ')
atresh=float(stv(0))
pstiff=float(stv(1))
plev=float(stv(2))
readf,unit,cteta0
readf,unit,npol

full_st={file:file,atresh:atresh,pstiff:pstiff,plev:plev,cteta0:cteta0,npol:npol}

close,unit
free_lun,unit

return,full_st

END