sgoldenlab / simba

SimBA (Simple Behavioral Analysis), a pipeline and GUI for developing supervised behavioral classifiers
https://simba-uw-tf-dev.readthedocs.io/
GNU General Public License v3.0
272 stars 137 forks source link

reciprocal directionality between animals #318

Closed filos93 closed 5 months ago

filos93 commented 5 months ago

Hey there, thanks again for the amazing software, I just wanted to ask whether there is the possibility of having a measure of reciprocal directionality between animals (ie, both animals are directed towards each other) in SimBA? It would be super helpful, in terms of social behavior analysis, to know when the animals are looking at each other at the same time. For now, I understand that you only can check when animal 1 is directed towards animal 2 or vice versa, but not the combined information. Please, let me know if I am missing something and what I'm proposing might be useful and doable. Many thanks again :)

sronilsson commented 5 months ago

Hi @filos93! I am not sure if this below is relevant, but if not, let me know why this wouldn't work and we can think of something else and make sure you get the output you are looking for:

There is a method in the GUI do compute "aggregate conditional boolean statistics" described HERE.

The method is used to string together a bunch of user-defined boolean (true vs false) conditions into a more complex condition, and compute the time in each video that strung together conditions is TRUE. For your scenario, it would be be a simpler input (animal_1 directs animal_2 = TRUE + animal_2 directs animal_1 = TRUE) that gives you the number of frames and time where both animal_1 directs animal_2 is true and animal_1 directs animal_2 is true.

filos93 commented 5 months ago

Ok, I got it, thank you so much, again thanks for the amazing software :)