Flux cookbook
Cookbook of utilities for flux calibration
Table of contents
Scale y axis
Method | CookbookFlux.y_scale |
Parameters |
|
JSON template | { "cookbook": "cb", "recipe": "y_scale", "params": { "fact": "1.0" } } |
Scale the y axis by a constant factor.
The y
and dy
columns of the spectrum and the line list (if present) are multiplied by fact
.
The scaling is done in place, without creating a new session.
Scale y axis by median
Method | CookbookFlux.y_scale_med |
Parameters | – |
JSON template | { "cookbook": "cb", "recipe": "y_scale_med", "params": { } } |
Scale the y axis by its median.
The y
and dy
columns of the spectrum and the line list (if present) are multiplied by the median of the spectrum y
.
The scaling is done in place, without creating a new session.
Scale y axis by its value at a given point
Method | CookbookFlux.y_scale_x |
Parameters |
|
JSON template | { "cookbook": "cb", "recipe": "y_scale_x", "params": { "x": "x" } } |
Scale the y axis by its value at a given point.
The y
and dy
columns of the spectrum and the line list (if present) are multiplied by the value of the spectrum y
at a given x
, computed with numpy.interp
.
The scaling is done in place, without creating a new session.
De-redden spectrum
Method | CookbookFlux.deredden |
Parameters |
|
JSON template | { "cookbook": "cb", "recipe": "deredden", "params": { "ebv": "0.03", "rv": "3.1" } } |
Correct the spectrum flux for reddening due to extinction.
The extinction is modeled with the parametrization of O’Donnell (1994), depending on the spectrum color excess \(E(B-V)\) and ratio of total selective extinction \(R(V)=A(V)/E(B-V)\). Column y
of the spectrum is updated with de-reddened values.