extime | R Documentation |
Calculate the time spent on the experiment. If not stated otherwise, the calculation only starts at the end of the first page!
extime(
oTree,
pcode = NULL,
plabel = NULL,
group_id = NULL,
seconds = FALSE,
rounded = TRUE,
digits = 2L,
startat = 1L,
tz = "UTC",
sinfo = "session_code",
combine = TRUE
)
oTree |
A list of data frames created
with |
pcode |
Character string.
The value of the |
plabel |
Character string.
The value of the |
group_id |
Integer. The value of the group_id variable if the
time should only be calculated for one specified group. The |
seconds |
Logical. |
rounded |
Logical. |
digits |
Integer. The number of digits to which the output
should be rounded.
This parameter has no effect unless |
startat |
Integer or character string |
tz |
Character string. Time zone. |
sinfo |
Character string. |
combine |
Logical. |
This functions calculates the time spent on the experiment by using
the variable that refers to the time stamp. If that variable is not
present, the function alternatively uses seconds_on_page2
,
which can be created with the pagesec()
function.
This function returns either a single value if only the data of one person is calculated or a list of information on the time several participants spent on the experiment.
In this list, you can find the following information:
$mean_duration
= The experiment's average duration.
$min_duration
= The experiment's minimum duration.
$max_duration
= The experiment's maximum duration.
$single_durations
= A data frame of all durations that
are used for calculating the min, max, and mean duration.
$messages
= All important notes to the calculations.
$only_one_page
= A vector of all individuals who
only have one time stamp.
# Use package-internal list of oTree data frames
oTree <- gmoTree::oTree
# Show time for one participant
extime(oTree, pcode = "wk247s9w")
# Make a data frame of durations
extime(oTree)
# Make a data frame of durations (beginning from the end of the second page)
extime(oTree, startat = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.