@@ -376,6 +376,15 @@ def line_amp_plot(spike_amps, spike_depths, spike_times, chn_coords, d_bin=10, d
376376
377377
378378def plot_brain_regions (channel_ids , channel_depths = None , brain_regions = None , display = True , ax = None ):
379+ """
380+ Plot brain regions along probe, if channel depths is provided will plot along depth otherwise along channel idx
381+ :param channel_ids: atlas ids for each channel
382+ :param channel_depths: depth along probe for each channel
383+ :param brain_regions: BrainRegions object
384+ :param display: whether to output plot
385+ :param ax: axis to plot on
386+ :return:
387+ """
379388
380389 if channel_depths is not None :
381390 assert channel_ids .shape [0 ] == channel_depths .shape [0 ]
@@ -414,7 +423,20 @@ def plot_brain_regions(channel_ids, channel_depths=None, brain_regions=None, dis
414423
415424
416425def plot_cdf (spike_amps , spike_depths , spike_times , n_amp_bins = 10 , d_bin = 40 , amp_range = None , d_range = None ,
417- display = False , cmap = 'hot' ):
426+ display = False , cmap = 'hot' ):
427+ """
428+ Plot cumulative amplitude of spikes across depth
429+ :param spike_amps:
430+ :param spike_depths:
431+ :param spike_times:
432+ :param n_amp_bins: number of amplitude bins to use
433+ :param d_bin: the value of the depth bins in um (default is 40 um)
434+ :param amp_range: amp range to use [amp_min, amp_max], if not given automatically computed from spike_amps
435+ :param d_range: depth range to use, by default [0, 3840]
436+ :param display: whether or not to display plot
437+ :param cmap:
438+ :return:
439+ """
418440
419441 amp_range = amp_range or np .quantile (spike_amps , (0 , 0.9 ))
420442 amp_bins = np .linspace (amp_range [0 ], amp_range [1 ], n_amp_bins )
0 commit comments