Skip to content
This repository has been archived by the owner on Jul 22, 2021. It is now read-only.

Unit conversion docs #531

Merged

Conversation

javerbukh
Copy link
Contributor

Documentation for unit conversion.

@javerbukh
Copy link
Contributor Author

@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?

@javerbukh javerbukh changed the title WIP: Refactor unit conversion docs Refactor unit conversion docs Nov 6, 2018
@javerbukh javerbukh requested review from nmearl and eteq November 6, 2018 13:56
@javerbukh javerbukh changed the title Refactor unit conversion docs WIP: Refactor unit conversion docs Nov 6, 2018
Copy link
Collaborator

@nmearl nmearl left a 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.

docs/unit_conversion.rst Outdated Show resolved Hide resolved
docs/unit_conversion.rst Outdated Show resolved Hide resolved
docs/unit_conversion.rst Show resolved Hide resolved
Copy link
Contributor

@eteq eteq left a 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.

@javerbukh javerbukh changed the title WIP: Refactor unit conversion docs Refactor unit conversion docs Nov 7, 2018
@javerbukh javerbukh changed the title Refactor unit conversion docs Unit conversion docs Nov 7, 2018
@nluetzge
Copy link
Collaborator

nluetzge commented Nov 8, 2018

How about adding a screenshot to to the main description? Just something like that:
screen shot 2018-11-08 at 1 34 46 pm

Otherwise it looks good to me.

@javerbukh javerbukh force-pushed the refactor_unit_conversion_docs branch from 2925ff2 to 0a9cc2e Compare November 9, 2018 17:08
@javerbukh javerbukh merged commit 5144c9d into spacetelescope:master Nov 9, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants