PRO liege2,wstart,wend,data,PLT=plt ;+ ; NAME: ; LIEGE2 ; PURPOSE: ; Extracts data from digitized version of Liege-Atlas ; (Disk centre intensity), range 3601 - 9301 A ;*CATEGORY: @CAT-# 31 32 25@ ; Spectral Analysis , Spectral Lines Identification , Plotting ; CALLING SEQUENCE: ; LIEGE,wstart,wend [,data] ; INPUTS: ; wstart : start wavelength (blue end of requested ; wavelength interval) in Angstroem. The actual start- ; value will be the largest integer <= wstart. ; If ** not ** set: procedure will set wstart = 3600. ; wend : end wavelength (red end of requested wavelength- ; interval) in Angstroem. ; If ** not ** set: procedure will set wend = 9301 ; KEYWORD: PLT - if set then a PS figure is made ; OUTPUTS: ; data : (short) integer-array containing the spectral intensities ; of the requested wavelength interval. Atlas-continuum =10000; ; wavelength step size: 2 mA. ; The spectrum in the interval is plotted. ; CALLING: procedure RESTORE2.PRO ; MODIFICATION HISTORY: ; ps, ??? ; nlte, 1990-Jul-17 : key-words FROM, TO, /PLOT ; nlte, 1992-Jun-10 : liege.dat now in /dat/daisy_2/spectral_atlas/ ; nlte, 1993-Apr-08 : GOOFY: liege.dat in /dat/goofy_2/spectral_atlas/ ; nlte, 1993-Apr-21 : use cd,current=cwd to get current working direct. ; 19/8/93 : data file in $IDL_DIR/data/kis_lib ; Reinhold Kroll 19/8/93 ; 23/3/09 : The procedure was changed to avoid UNIX/Linux dd command. ; The whole atlas is read into the memory, so that it works ; also under Windows. Michal Sobotka ;- on_error,1 ; atlas_file='C:\Users\Michal\DATA\PROGS\idlpro\liege.sav2' ;location of data ; if n_params() le 0 then begin wstart=3601 wend=9301 endif if n_params() le 1 then begin wend=9301 print,'Usage: LIEGE2, wstart (>=3600), wend (<=9301) [,output_data, /plt]' endif wl=fix(wstart) if wl lt 3600 then message,'wstart must be >= 3600' we=fix(wend) if we gt 9301 then message,'wend must be <= 9301' if we le wl then message,'LIEGE: wend must be > wstart' restore2,atlas_file,spe simax=(size(spe))(1) data=spe((wl-3600)*500L:((we-3600)*500L)<(simax-1)) n=(we-wl)*500L if min(data) ge 8000 then imin=8000 else imin=0 if max(data) le 2000 then imax=2000 else imax=10000 plot,wl+findgen(n)*0.002,data,/xst, $ yrange=[imin,imax],tit='Liege disk-centre atlas',xtit='Wavelength [A]' ; plot if keyword_set(plt) then begin set_plot,'PS' device,filename='liege_sp.ps',/landscape, $ xoffset=4.5,yoffset=27.,xsize=24,ysize=14,encapsulated=0 plot,wl+findgen(n)*0.002,data,/xst, $ yrange=[imin,imax],tit='Liege disk-centre atlas',xtit='Wavelength [A]' device,/close print,'PS file liege_sp.ps created.' ; !!!!! If you use Unix/Linux, replace 'WIN' by 'X' !!!!! set_plot,'WIN' endif end