swephR (version 0.2.1)

Section7: Section 7: Date and time conversion functions

Description

Functions related to calendar and time conversions.

Usage

swe_julday(year, month, day, hour, gregflag)

swe_date_conversion(year, month, day, hour, cal)

swe_revjul(jd, gregflag)

Arguments

year

Astronomical year as integer

month

Month as integer

day

Day as integer

hour

Hour as double

gregflag

Calendar type as integer (SE$JUL_CAL=0 or SE$GREG_CAL=1)

cal

Calendar type "g" [Gregorian] or "j" [Julian] as char

jd

Julian day number as double

Value

swe_date_conversion returns a list with named entries: return status flag as integer, jd Julian day number as double

swe_revjul returns a list with named entries: year year as integer, month month as integer, day day as integer and hour hour as double.

Details

swe_julday()

Convert calendar dates to the astronomical time scale which measures time in Julian day number.

swe_date_conversion()

Convert calendar dates to the astronomical time scale which measures time in Julian day number and checks if the calendar date is legal.

swe_revjul()

Compute year, month, day and hour from a Julian day number.

See Also

Section 7 in http://www.astro.com/swisseph/swephprg.htm

Examples

Run this code
# NOT RUN {
data(SE)
swe_julday(2000,1,1,12,SE$GREG_CAL)
swe_date_conversion(2000,1,1,12,"g")
swe_revjul(2452500,SE$GREG_CAL)
# }

Run the code above in your browser using DataCamp Workspace