Commit 9707968f37d8333e8b530587e7190a2c5ae8a09a

Authored by Jean-Philippe Bernard
1 parent 0939ca0c
Exists in master

added postscript capability

Showing 1 changed file with 25 additions and 1 deletions   Show diff stats
src/idl/dustem_run_readme.pro
1   -PRO dustem_run_readme,postcript=postcript,model=model,help=help,plot_it=plot_it,png=png
  1 +PRO dustem_run_readme,model=model,help=help,plot_it=plot_it,png=png,postcript=postcript
2 2  
3 3 ;+
4 4 ; NAME:
... ... @@ -68,6 +68,10 @@ IF keyword_set(png) THEN BEGIN
68 68 dir_png=!dustem_dat+'/Figures/'
69 69 force_mkdir,dir_png
70 70 ENDIF
  71 +IF keyword_set(postcript) THEN BEGIN
  72 + dir_ps=!dustem_dat+'/Figures/'
  73 + force_mkdir,dir_ps
  74 +ENDIF
71 75  
72 76 IF not keyword_set(dir) THEN BEGIN
73 77 ; CASE getenv('DUSTEM_WHICH') OF
... ... @@ -122,6 +126,16 @@ tit='Dustem Emitted Intensity '+use_model
122 126 yr=[1e-11,6.e-7]
123 127 xr=[1,5e3]
124 128 dustem_plot_nuinu_em,st,yr=yr,/ysty,xr=xr,/xsty,/xlog,/ylog,title=tit,xtit=xtit,ytit=ytit
  129 +IF keyword_set(postcript) THEN BEGIN
  130 + file_ps=dir_ps+'Last_dustem_run_readme_nuinuem.ps'
  131 + previous_device=!d.name
  132 + set_plot,'PS'
  133 + device,filename=file_ps
  134 + dustem_plot_nuinu_em,st,yr=yr,/ysty,xr=xr,/xsty,/xlog,/ylog,title=tit,xtit=xtit,ytit=ytit
  135 + device,/close
  136 + set_plot,previous_device
  137 + message,'Wrote '+file_ps,/continue
  138 +ENDIF
125 139  
126 140 ;== The following plots the resulting extinction
127 141 window,win & win=win+1
... ... @@ -131,6 +145,16 @@ xtit=textoidl('1/\lambda (\mum^{-1})')
131 145 ytit=textoidl('\sigma_{ext} (1e-21 cm^2/H)')
132 146 tit='Dustem extinction '+use_model
133 147 dustem_plot_extinction,st,st_model,xr=xr,yr=yr,/xsty,/ysty,xtit=xtit,ytit=ytit,title=tit
  148 +IF keyword_set(postcript) THEN BEGIN
  149 + file_ps=dir_ps+'Last_dustem_run_readme_extinction.ps'
  150 + previous_device=!d.name
  151 + set_plot,'PS'
  152 + device,filename=file_ps
  153 + dustem_plot_extinction,st,st_model,xr=xr,yr=yr,/xsty,/ysty,xtit=xtit,ytit=ytit,title=tit
  154 + device,/close
  155 + set_plot,previous_device
  156 + message,'Wrote '+file_ps,/continue
  157 +ENDIF
134 158  
135 159 IF keyword_set(png) THEN BEGIN
136 160 win=10L
... ...