R/bands.R
bands.Rd
See the parametric bootstrap algorithm in Politsch et al. (2020a) for details.
bands(obj, param, level = 0.95)
obj | An object of class |
---|---|
param | A string specifying which spectrum
to compute variability bands for. One of |
level | The level of the pointwise variability bands. Defaults to
|
A list of obj$n_segments
tibbles, each with the column set
c("wavelength","bootstrap_lower_band","bootstrap_upper_band")
.
Politsch et al. (2020a).
Trend filtering – I. A modern statistical tool for time-domain astronomy and
astronomical spectroscopy. MNRAS, 492(3), p. 4005-4018.
Politsch et al. (2020b). Trend Filtering – II. Denoising astronomical signals with varying degrees of smoothness. MNRAS, 492(3), p. 4019-4032.
data(polarized_spectrum_WR_star) wavelength <- seq( from = sci$axDat$crval[1], by = sci$axDat$cdelt[1], length = sci$axDat$len[1] ) flux <- as_tibble(sci$imDat) variance <- as_tibble(var$imDat) %>% select(1:3) mask <- as_tibble(bpm$imDat) spec_denoised <- denoise_spectrum( wavelength, flux, variance, mask, compute_uncertainties = TRUE ) spec_bands <- bands(spec_denoised, param = "Q_norm")