View source: R/utility_functions.r
collapse_time | R Documentation |
Summarize a dataframe to different units of analysis. The 'time.var' is divided by 'time.factor' and turned into an integer.
collapse_time(data, time.var, time.factor, group.by, variables)
data |
The data to summarize. |
time.var |
Symbols identifying the time variable in data. |
time.factor |
A number that 'time.var' will be divided by. |
group.by |
A vector of symbols that identify the unit of analysis. |
variables |
A list of variables to apply special functions to. |
A summarized dataframe.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.