This release significantly updates FRUITBAT
as specified below.
Highlights
- Dropped Python 2.7 support.
- Now using
pygedm
instead ofpyymw16
for galactic DM model. - Added
batten2021
hydrodynamic model for FRB redshift estimation. - Can now calculate FRB redshift PDFs and confidence intervals when using a hydrodynamic model.
- New functions for calculating quantities from PDFs.
- Plot the redshift PDF and confidence interval with
plot.redshift_pdf()
. - Now using HDF5 backend.
Change Log
-
Dropped support for Python 2.7
-
Updates to the model backend to use HDF5 files instead of .npz
- All models are now saved and stored as hdf5 files.
- New models generated with the
table.create()
function are also saved as HDF5 files.
-
Now uses PyGEDM as the galactic electron density model.
- This means that both NE2001 and YMW2016 models are included by default with fruitbat.
- Also includes the YT2020 galactic halo model
-
New Model:
Batten2021
(hydrodynamic)- New hydrodynamic model included from Batten et al. (2021).
- See https://doi.org/10.1093/mnras/stab1528 for the paper.
-
New
Fruitbat.Frb
class features:- New default method "Batten2021" replaces "Inoue2004".
*Addedcalculate_redshift_pdf()
- Calculates the redshift PDF using a hydrodynamic method.
- Added
calculate_redshift_conf_int()
- Calculates the redshift confidence intervals for a given sigma assuming a hydrodynamic model.
- Added
plot_redshift_pdf()
- Create a plot of the redshift PDF of the FRB with confidence intervals.
- New keywords for calc_dm_galaxy()`:
include_halo
: Also include the galactic halo (from YT2020) that isn't included in YMW16 or NE2001.return_tau_sc
: to also return the scattering timescale at 1 GHz
- New property
galaxy_model
that knows which Milky Way model was used when subtracting galactic DM.
- New default method "Batten2021" replaces "Inoue2004".
-
New
fruitbat.methods
features:- Added new type of methods "hydrodynamic" which can return the redshift PDF at a specific DM value.
- Added
batten2021()
hydrodynamic method from Batten et al. (2021) - Added
methods_analytic()
andmethods_hydrodynamic()
for specifying the different types of methods.
-
New
fruitbat.plot
features:- New plotting function:
redshift_pdf()
for plotting the redshift PDF of an FRB calculated with a hydrodynamic method.
- New plotting function:
-
New
fruitbat.utils
features:- Added new utility functions for calculating parameters from a PDF.
calc_mean_from_pdf()
calc_variance_from_pdf()
calc_std_from_pdf()
calc_median_from_pdf()
calc_z_from_pdf_percentile()
- Added functions to manipulate PDFs:
- Normalise pdfs:
normalise_to_pdf()
- Interpolate between two PDFs:
linear_interpolate_pdfs()
- Normalise pdfs:
- Added function to calculate percentiles from a sigma:
sigma_to_pdf_percentiles()
. - Added function for including a redshift prior:
redshift_prior()
. Currently only uniform is available.
- Added new utility functions for calculating parameters from a PDF.
-
Misc Changes:
- New CITATION File
- New function
fruitbat.get_bibtex()
to obtain bibtex for referencingFRUITBAT
. - Converted to using Github actions for testing instead of Travis CI.
- Added ASCL badge.
- Updated requirements to include
h5py
andpygedm
.