Skip to content

Commit

Permalink
add .get_timestamps to tutorial (#1879)
Browse files Browse the repository at this point in the history
  • Loading branch information
bendichter authored Apr 1, 2024
1 parent af63c5f commit 9af54a2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/gallery/general/plot_read_basics.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,9 @@
after = 3.0

# Get the stimulus times for all stimuli
stim_on_times = stimulus_presentation.timestamps[:]
# get_timestamps() works whether the time is stored as an array of timestamps or as
# starting time and sampling rate.
stim_on_times = stimulus_presentation.get_timestamps()

for unit in range(3):
unit_spike_times = nwbfile.units["spike_times"][unit]
Expand Down

0 comments on commit 9af54a2

Please sign in to comment.