isi_distribution

Contents

isi_distribution#

class braintools.visualize.isi_distribution(spike_times, bins=50, max_isi=None, log_scale=False, ax=None, figsize=(10, 6), color='blue', alpha=0.7, xlabel='Inter-Spike Interval', ylabel='Count', title=None, **kwargs)#

Plot inter-spike interval (ISI) distribution.

Parameters:
  • spike_times (ndarray | List) – Spike times or list of spike time arrays.

  • bins (int | ndarray) – Number of bins or bin edges.

  • max_isi (float | None) – Maximum ISI to include.

  • log_scale (bool) – Whether to use log scale for y-axis.

  • ax (Axes | None) – Axes to plot on.

  • figsize (Tuple[float, float]) – Figure size if creating new figure.

  • color (str) – Bar color.

  • alpha (float) – Alpha transparency.

  • xlabel (str) – Axis labels and title.

  • ylabel (str) – Axis labels and title.

  • title (str | None) – Axis labels and title.

  • **kwargs – Additional arguments passed to hist.

Returns:

ax – The axes object containing the plot.

Return type:

Axes