# Nesting over behaviors of Rat/Mouse Behavior Recognition

Aim

To pick out the samples collected when the subject was in one or more of the behavioral states detected using the Rat or Mouse Behavior Recognition function:

Digging (only for mice) | Rearing unsupported
Drinking | Rearing supported
Eating | Resting
Grooming | Sniffing
Jumping (only for rats) | Walking
Merged behavior

example You want to visualize where in the arena Grooming occurred. First, nest over Grooming (see the procedure below), then create heatmaps.

Procedure

1.In the Data Profiles screen, under Nesting, click the button corresponding to the behavior you want to use to select the track segments.

2.In the window that appears, select the properties and which state you want to consider for nesting. Then, click OK. See also Behavior Recognition in the Analysis profile.

If you want to analyze the track segments in which the behavior was not active, select Not [behavior name].

3.Click OK. Proceed with step 4 on How to select track segments.

Options

Behavior decision method

The Behavior decision method acts as a filter that you can use to ignore samples where the behavior’s probability is below a certain value. Default means that EthoVision uses the original scores (thus no filtering based on probabilities).

The figure below shows the effect of Behavior decision method on the track segment selected for analysis. Top: The probability of Grooming, and another behavior plotted against time (for simplicity, other behaviors are ignored here). Bottom: When Nesting over Grooming. With Default selected, analysis is done on the samples for which the probability of Grooming exceeds the probability of any other behavior (default behavior recognition). With a set Probability > 50%, analysis is done on the samples for which the probability is higher than 50%. The higher the value, the more conservative the selection.

▪If you want to select the samples when a behavior probability was lower than a certain value, choose that value, then under Calculate nesting for, select Not [behavior name].

▪To choose a specific probability threshold, it is best to view the per-sample values of probability for that behavior. In the Analysis profile, under Rat/Mouse Behavior Recognition select Behavior probability, and select the behavior(s) you are interested in. Choose Plot Integrated Data to see the probability values plotted against time.

Notes (all behaviors)

▪This nesting option is only available if you have the Rat or Mouse Behavior Recognition add-on module.

▪Since Hopping (mouse behavior) and Twitching are events with no duration, it is not possible to nest over those behaviors.

▪If you want to pick out samples based on two or more behaviors and analyze them together as if they were one (for example, Rearing unsupported and Rearing supported), click next to Merged Behavior instead. See Notes about Merged behavior

▪If you want to calculate duration of a behavior as a percentage of a track, but excluding the time scored as Unknown, make two nesting criteria, one with [behavior name] and the other with Not [behavior name] selected. Combine the resulting boxes with OR logic and then in the Analysis profile define the behavior you are interested in, and under Trial statistics choose the statistic Cumulative Duration within Nesting (%).

▪The Behavior duration threshold acts as a filter to ignore short transitions between states. See also Behaviors detected with Behavior recognition in the Analysis profile.

Notes about Merged behavior

▪Nesting over Merged behavior. When you select multiple behaviors under Merged behavior, the track segments are selected in which the subject was in one of the selected states, and then combined with OR logic.

▪Nesting over “Not” Merged behavior. The Merged Behavior window does not allow you to select Not [behavior name]. If you want to select the samples when two or more behaviors were not active, then make a Nesting criterion for each behavior, selecting Not [behavior name], then place the resulting Nest boxes in a linear sequence (see Basic rules for combining selection boxes).

Note that the track segments are not selected when the behavior is Unknown, or when no behavior is scored in that segment (this is represented as a gap between behaviors).