Learn R Programming

⚠️There's a newer version (1.9.4) of this package.Take me there.

lubridate (version 0.2.6)

Make dealing with dates a little easier

Description

Lubridate makes it easier to work with dates and times by providing functions to identify and parse date-time data, extract and modify components of a date-time (years, months, days, hours, minutes, and seconds), perform accurate math on date-times, handle time zones and Daylight Savings Time. Lubridate has a consistent, memorable syntax, that makes working with dates fun instead of frustrating.

Copy Link

Version

Install

install.packages('lubridate')

Monthly Downloads

947,479

Version

0.2.6

License

GPL

Maintainer

Garrett Grolemund

Last Published

January 10th, 2012

Functions in lubridate (0.2.6)

DateUpdate

Changes the components of a date object
ceiling_date

Round date-times up.
add_epoch_to_date

Add epochs to dates
is.duration

Is x a duration object?
dseconds

Quickly create exact time spans.
force_tz

Replace time zone to create new date-time
new_interval

Create an interval object.
origin

1970-01-01 GMT
seconds

Quickly create relative timespans.
hour

Get/set hours component of a date-time.
hm

Create a period with the specified number of hours and minutes
add_dates

Adding date-time objects
leap_year

Is a year a leap year?
reclass_date

Convenience method to reclass dates post-modification.
floor_date

Round date-times down.
week

Get/set weeks component of a date-time.
make_difftime

Makes a difftime object from a given number of seconds
wday

Get/set days component of a date-time.
year

Get/set years component of a date-time.
as.duration

Change an object to a duration (difftime).
yday

Get/set days component of a date-time.
subtract_dates

Subtracting date-time objects
new_duration

Create a duration object.
pretty.dates

Computes attractive axis breaks for date-time data
dst

Get Daylight Savings Time indicator of a date-time.
lakers

Lakers 2008-2009 basketball data set
decimal_date

Converts a date to a decimal of its year.
hms

Create a period with the specified hours, minutes, and seconds
tz

Get/set time zone component of a date-time.
is.difftime

Is x a difftime object?
new_epoch

Create an epoch object
today

The current date
is.POSIXt

Is x a POSIXct or POSIXlt object?
as.interval

Change an object to an interval.
round_date

Rounding for date-times.
with_tz

Get date-time in a different time zone
duration

Description of time span classes in lubridate.
second

Get/set seconds component of a date-time.
month

Get/set months component of a date-time.
ymd

Parse dates according to the order that year, month, and day elements appear
is.period

Is x a period object?
minute

Get/set minutes component of a date-time.
now

The current time
ms

Create a period with the specified number of minutes and seconds
ymd_hms

Parse dates that have hours, minutes, or seconds elements
lubridate

Dates and times made easy with lubridate
is.Date

Is x a Date object?
sundays

Quickly create common epoch objects
is.instant

Is x a date-time object?
int_start

Access and change the start date of an interval
is.timespan

Is x a length of time?
new_difftime

Create a difftime object.
as.period

Change an object to a period.
int_end

Access and change the end date of an interval
am

Does date time occur in the am or pm?
DateCoercion

Convert every date method we know about to POSIXlt and POSIXct
new_period

Create a period object.
parse_date

Change dates into a POSIXct format
is.interval

Is x an interval object?