Commit 0bbec0057658b0e5c00f6ebbdda9d2240b1d6ba7

Authored by Jean-Philippe Bernard
1 parent 5472080a
Exists in master

improved

Showing 1 changed file with 4 additions and 4 deletions   Show diff stats
src/idl/dustem_brute_force_fit.pro
... ... @@ -149,11 +149,11 @@ best_grid_sed=reform(grid_seds[ind[0],*]) ;This is the best SED fround in the
149 149 best_sed=best_grid_sed*fact ;This is the best scaled grid SED matching the input SED.
150 150  
151 151 ;=== compute Likelyhood weighted params values
152   -weighted_params=fltarr(Nparams)
153   -weights=1./chi2s
154   -tot_weights=la_tot(weights)
  152 +weighted_params=dblarr(Nparams)
  153 +weights=1.d0/chi2s
  154 +tot_weights=total(weights)
155 155 FOR i=0L,Nparams-1 DO BEGIN
156   - weighted_params[i]=la_tot(reform(grid_param_values[*,i])*weights)/tot_weights
  156 + weighted_params[i]=total(reform(1.d0*grid_param_values[*,i])*weights)/tot_weights
157 157 ENDFOR
158 158  
159 159 ;==== Check bumping to table edges.
... ...