Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions docs/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@ To use Python Lunar in a project::

>>> import pylunar

Location: Boston, MA, USA
Get moon info by entering the location using DMS coordinates.
Example: Location - Wellington, New Zealand
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The numeric coordinates specified in the following line are for Boston not Wellington, so the location text should be Boston, MA, USA like the original. This also matches the time zone adjustment below which is set for Boston and not Wellington.


>>> mi = pylunar.MoonInfo((42, 21, 30), (-71, 3, 35))

Local Time: July 18, 2016 at 21:45

API requires UTC, so add 4 hours since on Daylight Savings (changes day)
API requires UTC, so adjust local timezone to utc.
Example: adds 4 hours since Daylight Savings (changes day)

>>> mi.update((2016, 7, 19, 1, 45, 0))
>>> mi.age()
Expand Down