bin_avg

tayph.bin_avg(wl, fx, wlm)[source] [edit on github]

A simple function to bin a high-res model spectrum (wl,fx) to a lower resolution wavelength grid (wlm), by averaging the points fx inside the lower-resolution wavelength bins set by wlm.

Parameters
wllist, np.ndarray

The horizontal axis.

fxlist, np.ndarray

The array corresponding to x.

wlmlist, np.ndarray

The lower resolution wlm array. wlm should have fewer points than wl and fx.

Returns
y_binnp.array

The binned flux points.