# Swap nose-point and tail-base point automatically

With automatic swapping, EthoVision looks for the samples where the subject made a turn exceeding a user-specified threshold relative to the previous sample. These turns are interpreted as nose-point and tail-base being incorrectly assigned. You can then select those samples and let EthoVision exchange the corresponding nose-point and tail-base.

Use this method when a large number of consecutive samples have body points wrongly assigned.

What does 'turn' mean here?

Turn is referred to the change in orientation of the nose-tail base vector. The nose-tail base vector is the vector connecting the nose-point and the tail-base point within a sample (see the dotted arrow in the picture below). With automatic swapping, if the change in the vector's direction from sample n to n+1, is larger than the angle you specify, the sample n+1 is considered for swapping. Then, it is up to you to decide whether to swap the points.

If the nose-point or the tail-base is missing, the nose-tail base vector is the vector connecting the center with the other point. If both nose- and tail-base points are missing, the sample is not considered for swapping anyway.

If samples following n+1 have a vector's turn lower than the specified threshold, they too are assumed to have nose-point and tail-base detected wrongly. Therefore, they are included in the swapping interval (see samples under B in the figure below).

example A: the body points are assigned correctly. B: the nose-tail base vector (indicated with the black arrow) makes a turn greater than the specified threshold (for example, 150°). This is the start of the swapping interval. C: a new significant turn of the nose-tail base vector is found. Samples between B and C (not included) are swapped. The samples after C are considered correct, until a new significant turn is found.

To swap body points automatically

1.Position the track at the beginning and check whether the first sample in your track is orientated correctly.

To check this: If you have tracked data from a video file, make sure that the video file is on the background. If you have tracked live, make sure that the nose-tail base orientation matched the direction of movement.

2.Click the Auto Swap button on the toolbar, or press Ctrl+F.

3.In the Auto Swap Nose-Tail window, under Find Interval, do the following:

▪From the Find nose-tail swaps in the track list, select the arena and the subject you want to search. For single-arena setups and single-subject setups, only one arena/subject is available, so go to the next step.

▪In the Turning angle threshold field, enter the threshold angle. The first sample with a change in orientation of the nose-tail base vector larger than this threshold is considered for swapping.

4.Click the Next >> button.

Result: A number of samples are highlighted (selected). Under Find Interval, the following times are displayed:

▪Start sample found at: The time of the sample in the track with turning angle greater than the threshold relative to the previous sample. It is the start of the interval of samples considered for swapping.

▪Stop sample found at: The time of the sample immediately preceding the sample with turning angle greater than the threshold. It is the end of the interval of samples considered for swapping.

5.Do one of the following:

If the first sample of the selected interval in your track is oriented correctly, click the Next >> button until the first sample of the new interval is not oriented correctly.

If the first sample of the selected interval is not oriented correctly, this is the start of the interval of samples to be swapped. Proceed to step 6.

6.Once you have selected an interval of samples that does not match the orientation of the animal, do one of the following:

▪If you want to let EthoVision XT swap the intervals of samples throughout the track based on the above criteria, select the option Automatically swap the current selection and swapped intervals in the remainder of the track, and click the Swap button in the Auto Swap Nose-Tail window.

▪If you only want to swap the selected interval, make sure that the option above is cleared and click the Swap button in the Auto Swap Nose-Tail window.

Result: The nose-point and tail-base in the selected intervals are swapped.

7.Do one of the following:

▪If you want to search for the next interval to be swapped, go back to step 5.

▪If the track contains only samples oriented correctly, click the Close button.

To swap nose-point and tail-base in another arena, select that arena from the appropriate list.

Notes

▪When you click Next>> for the first time, the interval from the start of the track (0:00:00.000) to the first change in the nose-tail vector orientation greater than the threshold is displayed. If you click the Next>> button more times, other intervals are displayed depending on where in the track other significant turns are found.

▪Select the Automatic swap option above only if you are confident that the angle threshold specified in step B results in identifying the correct intervals to be swapped. This usually happens when you have checked the intervals yourself a few times.

▪If you select points outside the Auto Swap Nose-Tail window, the Start sample found at and Stop sample found at fields show <Selection changed>. In this case the Automatic swap option is not available. Click the <<Previous button to return to one of the sample intervals found by the program.

▪If you want to view the movement of the subject around the selected sample, click the Play button in the Preview Interval group. If you want to view additional samples immediately before the start and after the end of the selected interval, enter the number of such samples in the Expand preview with box.

▪To go back in the track and select the previous intervals that start and stop at samples where the turn angle exceeds the threshold, click the <<Previous button.

▪If you want to undo the swap action, click the Swap button again.