engagement#

Engagement: how the animal used its time in the box during each session.

Functions

add_engagement_column

find_next_end_task_time_in_events

Find the end task time in the events dataframe for a given date.

get_box_usage_df

Time of each session spent completing the first trial, engaged, disengaged, unaccounted and exiting the box (see get_session_box_usage), with the session end taken from events_df (see get_session_ends).

get_session_box_usage

get_session_ends

End of each session (subject, date) of df: the first time the same subject returned home ("Subject back home: ..." or "The subject has returned home.") after the session started, before its next session started and at most max_hours later.