powered by
Interconverts dates in a variety of calendars.
convert(from, to, ...)# S4 method for character,character convert(from, to)# S4 method for TimeScale,TimeScale convert(from, to)
# S4 method for character,character convert(from, to)
# S4 method for TimeScale,TimeScale convert(from, to)
A function that when called with a single numeric argument (factional years) converts years from one calendar to another.
function
A TimeScale object describing the source calendar.
TimeScale
A TimeScale object describing the target calendar.
Currently not used.
N. Frerebeau
Other calendar tools: calendar(), calendar_get, get_calendar(), gregorian, is_calendar(), julian()
calendar()
calendar_get
get_calendar()
gregorian
is_calendar()
julian()
## Define time scales BP <- calendar("BP") AD <- calendar("AD") ## Make conversion functions BP_to_AD <- convert(BP, AD) AD_to_BP <- convert(AD, BP) ## Convert years BP_to_AD(0) AD_to_BP(1950)
Run the code above in your browser using DataLab