View source: R/regularize_activity.R
regularize_activity | R Documentation |
regularize_activity
regularizes the timestamps within the
$acticity_data
of an activity
object (column 'ts') to
regular intervals for each animal_tag. The interval is defined by the
parameter minutes
. The following steps are performed:
regularize_activity(activity, act.reg_minutes = NULL)
activity |
An object of class |
act.reg_minutes |
The regular interval in minutes. |
Round each timestamp to the nearsed regular timestamp.
When several data points occur with the same regularized timestamp, aggregate these by calculating the mean of the activity values.
Insert data points for missing regularized timestamps with NA-activity values .
The original activity object with regularized timestamps for its
$acticity_data
in column 'ts'.
activity_data <- regularize_activity(data = activity_data, minutes = 5)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.