astropy:docs

TimeDatetime

class astropy.time.TimeDatetime(val1, val2, scale, precision, in_subfmt, out_subfmt, from_jd=False)[source] [edit on github]

Bases: astropy.time.core.TimeUnique

Represent date as Python standard library datetime object

Example:

>>> from datetime import datetime
>>> t = Time(datetime(2000, 1, 2, 12, 0, 0), scale='utc')
>>> t.iso
'2000-01-02 12:00:00.000'
>>> t.tt.datetime
datetime.datetime(2000, 1, 2, 12, 1, 4, 184000)

Attributes Summary

name
value

Methods Summary

set_jds(val1, val2) Convert datetime object contained in val1 to jd1, jd2

Attributes Documentation

name = u'datetime'
value

Methods Documentation

set_jds(val1, val2)[source] [edit on github]

Convert datetime object contained in val1 to jd1, jd2

Page Contents