Skip to content

Commit

Permalink
fix: add suggested doctstring from reviewer
Browse files Browse the repository at this point in the history
  • Loading branch information
MilagrosMarin committed Nov 13, 2024
1 parent 387277b commit 50f5ff1
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions aeon/dj_pipeline/utils/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,17 @@


def plot_reward_rate_differences(subject_keys):
"""Plotting the reward rate differences between food patches (Patch 2 - Patch 1) for all sessions from all subjects specified in "subject_keys".
"""Plots the reward rate differences between two food patches (Patch 2 - Patch 1).
Examples:
```
subject_keys =
(acquisition.Experiment.Subject & 'experiment_name = "exp0.1-r0"').fetch('KEY')
The reward rate differences between the two food patches are plotted
for all sessions from all subjects in ``subject_keys``.
fig = plot_reward_rate_differences(subject_keys)
```
""" # noqa E501
Examples:
>>> subject_keys = (
... acquisition.Experiment.Subject
... & 'experiment_name = "exp0.1-r0"').fetch('KEY')
>>> fig = plot_reward_rate_differences(subject_keys)
"""
subj_names, sess_starts, rate_timestamps, rate_diffs = (
analysis.InArenaRewardRate & subject_keys
).fetch("subject", "in_arena_start", "pellet_rate_timestamps", "patch2_patch1_rate_diff")
Expand Down

0 comments on commit 50f5ff1

Please sign in to comment.