is.instant: Is x a date-time object?

View source: R/instants.r

is.instantR Documentation

Is x a date-time object?

Description

An instant is a specific moment in time. Most common date-time objects (e.g, POSIXct, POSIXlt, and Date objects) are instants.

Usage

is.instant(x)

is.timepoint(x)

Arguments

x

an R object

Value

TRUE if x is a POSIXct, POSIXlt, or Date object, FALSE otherwise.

See Also

is.timespan(), is.POSIXt(), is.Date()

Examples

is.instant(as.Date("2009-08-03")) # TRUE
is.timepoint(5) # FALSE

hadley/lubridate documentation built on Feb. 3, 2024, 9:37 a.m.