I'm thinking the write_latex(...) method would call cosmology.io.table.to_table(), format the table to e.g. make H0 -> $H_0 \rm{[Mpc]}$ or something and then call the QTable.write(..., format='latex').
The text was updated successfully, but these errors were encountered:
nstarman
changed the title
Register format latex to the write method for exporting a Cosmology to a nice Latex table.
Register latex to Cosmology.writeNov 2, 2021
@Octaves0911, that would be great! No one else is currently working on this feature request. If you need any help or have any questions I am happy to help. You can post here, or in the Astropy Slack cosmology channel. We also have documentation to assist in contributing at https://www.astropy.org/contribute.html#contribute-code-or-docs.
Cosmology can now read and write to files.
It would be nice to register with
Cosmology.writea method for exporting a Cosmology to a Latex table.There are good examples of IO with Cosmology at https://github.com/astropy/astropy/tree/main/astropy/cosmology/io
and documentation at https://docs.astropy.org/en/latest/cosmology/io.html#cosmology-io
I'm thinking the
write_latex(...)method would callcosmology.io.table.to_table(), format the table to e.g. makeH0->$H_0 \rm{[Mpc]}$or something and then call theQTable.write(..., format='latex').The text was updated successfully, but these errors were encountered: