[tubingen] analysis of angles relative to center
This commit is contained in:
parent
75da6e7eb9
commit
0c2549dea5
@ -8,7 +8,7 @@ import os
|
||||
from IPython import embed
|
||||
import pycircstat as stats
|
||||
|
||||
from tracking_result import TrackingResult
|
||||
from etrack import TrackingResult
|
||||
|
||||
fish_color = {'2019lepto03': {'main': 'red', 'dark': 'darkred', 'light': 'indianred'},
|
||||
'2020lepto20': {'main': 'orange','dark': 'sienna', 'light': 'sandybrown'},
|
||||
@ -169,6 +169,8 @@ if __name__ == "__main__":
|
||||
|
||||
if len(all_joined) > 0:
|
||||
attracted, repelled, interacting, avoiding = characterize_behavior_all(np.array(all_joined))
|
||||
#attracted, repelled, interacting, avoiding = characterize_behavior(all)
|
||||
|
||||
results.append({"subject": subject, "light_condition": light, "stimulus": stim, "attracted": attracted,
|
||||
"repelled": repelled, "interacting": interacting, "avoiding": avoiding})
|
||||
plot_angles(np.array(all_joined), stim, light, ax=axis, color=fish_color[subject]["dark"])
|
||||
@ -178,6 +180,7 @@ if __name__ == "__main__":
|
||||
fig.savefig("%s_preferred_angles.pdf" % subject)
|
||||
plt.close()
|
||||
results_df = pd.DataFrame(results)
|
||||
results_df.to_csv("behavior_results_simple.csv", sep=";")
|
||||
embed()
|
||||
|
||||
# does the fish go to the previous stimulus location?
|
Loading…
Reference in New Issue
Block a user