| DiffPeriod | R Documentation | 
DiffYearComputes the difference in years between two dates.
DiffPeriod(from, to, by, ceiling = FALSE)
from | 
 The earlier date.  | 
to | 
 The later date.  | 
by | 
 The period used in the conversion. Either "Week", "month", "quarter", or "year".  | 
ceiling | 
 If TRUE, rounds partial-year differences up (otherwise they are rounded down). Ignores seconds, minutes, and hours.  | 
Dates of 29th of Feb are automatically converted to "2016-02-28" to deal with bugs in lubridate.
An integer.
DiffPeriod("2015/05/06", "2017/05/06", by = "year")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.