View source: R/DbiDateFunctions.R
dateDiff | R Documentation |
This function is provided primarily to be used together with dbplyr
when querying
a database. It will also work in dplyr
against data frames.
dateDiff(interval, date1, date2)
interval |
Unit for the interval. Can be "day", "week", "month", "year". |
date1 |
The first date. |
date2 |
The second date. |
The numeric value of the difference.
dateDiff("day", as.Date("2000-01-01"), as.Date("2000-03-01"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.