Unit conversion docs #531
Unit conversion docs #531
Conversation
@brechmos-stsci @eteq I have written some documentation for unit conversion, however this is my first time writing a .rst file, so I'm not sure if this is how it should look. Can you guys let me know about any changes that need to be made? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few minor things to keep in mind.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
High-level comment: if you use the >>>
syntax instead of just relying on .. code-block::
, code in .rst
files get run as doctests. That is, when you run the tests, it will run any code in the >>>
section and make sure it responds as expected. That makes sure the examples are actually accurate. By >>>
syntax I mean:
.. code-block:: python
>>> import astropy.units as u
>>> potential_X_axis_units = ...
That said, I'm not entirely sure that's been turned on in specviz
yet, but I find it's usually a good idea to do that so that things are ready if/when it is.
2925ff2
to
0a9cc2e
Compare
Documentation for unit conversion.