melt_date | R Documentation |
This function returns a data frame in long format, where the dates are completed from start to end by some id.
melt_date(data, start, end, id)
data |
Object of type dataframe |
start |
date type value |
end |
date type value |
id |
Character value that will be used as id to melt the data frame from start to end by dates |
data_example = data.frame(id = c(1, 2), start = as.Date(c("2021-01-01", "2021-01-10")), end = as.Date(c("2021-01-10", "2021-01-15"))) melt_date(data = data_example, start = start, end = end, id = id)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.