phangs_compare_seds_isrf.pro 1.02 KB

PRO phangs_compare_seds_isrf

dir=!phangs_data_dir+'/ISRF/GRIDS/'
isrf_class_str='_isrfclass15'
model='DBP90'
table_name=dir+model+'_MuseISRF_JWST_G0_YPAH_YVSG_4Phangs'+isrf_class_str+'.fits'
st=mrdfits(table_name,1,h)

filters=['NIRCAM1','MIRI2']
Nfilters=n_elements(filters)

ii=100L
sed=fltarr(Nfilters)
tags=tagnames(st)
FOR i=0L,Nfilters-1 DO BEGIN
	ind=where(tags EQ 'I'+filters[i],count)
	sed[i]=st[ii].(ind[0])
ENDFOR
Nparams=3
true_params=fltarr(Nparams)
FOR i=0L,Nparams-1 DO BEGIN
  true_params[i]=st[ii].(i)
ENDFOR


isrf_class_str='_isrfclass0'
table_name_2=dir+model+'_MuseISRF_JWST_G0_YPAH_YVSG_4Phangs'+isrf_class_str+'.fits'

params=dustem_brute_force_fit(sed,table_name_2,filters,fact=fact,chi2=chi2,/normalize,rchi2=rchi2,show_sed=show_sed $
		   					 ,params_hit=params_hit,params_uncertainties=params_uncertainties,params_min=params_min,params_max=params_max $
		   					 ,fixed_parameters_description=fixed_parameters_description,fixed_parameters_values=fixed_parameters_values)

print,true_params
print,params

stop

END