single_cell_parseranalyzemembrane_potential_analysisPSTH_from_spike_times

PSTH_from_spike_times

single_cell_parser.analyze.membrane_potential_analysis.PSTH_from_spike_times(spikeTimeVectors, binSize=1.0, tBegin=None, tEnd=None, aligned=True)

Calculates a PSTH from spike times.

Parameters:
  • spikeTimeVectors (list) – List of spike time vectors.

  • binSize (float, optional) – Bin size for the PSTH. Default is 1.0 ms.

  • tBegin (float, optional) – Start time of the PSTH. Default is None (min of spikeTimeVectors).

  • tEnd (float, optional) – End time of the PSTH. Default is None (max of spikeTimeVectors).

  • aligned (bool, optional) – If True, aligns the bins to integer multiples of the bin size. Default is True.

Returns:

Tuple containing the histogram and the bins.

Return type:

tuple