natural_time {humanize} | R Documentation |
Convert times to natural values relative to now.
Description
Given a datetime or a number of seconds, return a natural representation of that resolution that makes sense. Ago/From now determined by positive or negative values.
Usage
natural_time(value, use_months = TRUE)
Arguments
value |
a datetime or a number of seconds |
use_months |
Boolean whether we should (imprecisely) use months as a unit |
Examples
natural_time(Sys.time()-1)
natural_time(Sys.time()-100)
[Package humanize version 0.2.0 Index]