Version 5.2
The best method to read INES files in IDL is with the "MRDFITS'' function, which stores the data into an IDL structure with four tags: Wavelength, Flux, Sigma and Quality:
IDL> data=mrdfits('SWP25774LL.FITS',1,str='INES') MRDFITS: Binary table. 4 columns by 495 rows. IDL> help,data,/st ** Structure INES, 4 tags, length=16: WAVELENGTH FLOAT 1150.58 FLUX FLOAT -2.65123e-14 SIGMA FLOAT 3.98036e-14 QUALITY INT 0 IDL> help,data.flux <Expression> FLOAT = Array(495) IDL> for i=300,304 do print,data(i).wavelength,data(i).flux,data(i).sigma,data(i).quality 1653.50 1.62347e-14 3.68273e-15 0 1655.18 1.53256e-14 3.69914e-15 -32 1656.85 1.96984e-14 3.80942e-15 -4128 1658.53 1.57936e-14 3.67132e-15 -4128 1660.21 1.22920e-14 3.64177e-15 -4096
MRDFITS also allows to select a range of rows and/or columns. To read a range of wavelengths:
IDL> data=mrdfits('LWP07371LL.FITS',1,str='INES',range=[200,300]) MRDFITS: Binary table. 4 columns by 101 rows. IDL> help,data,/st ** Structure INES, 4 tags, length=16, refs=1: WAVELENGTH FLOAT 2385.29 FLUX FLOAT 2.37237e-13 SIGMA FLOAT 3.38377e-14 QUALITY INT 0 IDL> help,a.wavelength <Expression> FLOAT = Array(101) IDL> print,minmax(a.wavelength) 2385.29 2652.22
To select columns:
IDL> data=mrdfits('LWP07371LL.FITS',1,columns=[1,2]) MRDFITS: Binary table. 4 columns by 562 rows. IDL> help,data,/st ** Structure INES, 2 tags, length=8, refs=1: WAVELENGTH FLOAT 1851.43 FLUX FLOAT 2.82831e-13
The bi-dimensional SILO files can be read with the command "READFITS":
IDL> silo=readfits('SWP43250.SILO') % READFITS: File may contain FITS extensions % READFITS: Now reading 640 by 80 array IDL> help,silo SILO FLOAT = Array(640, 80)
The bi-dimensional quality-flag image is stored as an image extension of the SILO file. It can also be read with "READFITS":
IDL> silo_nu=readfits('SWP43250.SILO',ext=1) % READFITS: Reading FITS extension of type IMAGE % READFITS: Now reading 640 by 80 array IDL> help,silo_nu SILO_NU INT = Array(640, 80) IDL> print,minmax(silo_nu) -16384 0