Peristimulus Time Histogram & Smoothing

Hi All,
I have a couple questions regarding computation of a peristimulus time-histogram, computation of a spike average from the binned data, and subsequent smoothing for visualization.
My inputs are:
cluster_split(1 x 3 cell) - this is a cell matrix, where each cell consists of a matrix of neuron spike times (in seconds)
recEv (1x97 struct) - this is an event structure; one of the fields "eegoffset" corresponds to the time (in seconds) that my event of interest occurs
I am using this toolbox (specifically the mpsth.m function) to build my PSTH (https://www.mathworks.com/matlabcentral/fileexchange/37339-mlib-toolbox-for-analyzing-spike-data).
My questions are as follows:
1) How do I select a proper bin size?
2) Is there a way to construct a PSTH with overlapping bins? i.e.: bin 1 = -1000ms to -900 ms, bin 2 = -950 ms to -850 ms etc etc. Would this be a better way of doing this?
3) I'd like to calculate the firing rate for each bin and then plot it. If I set the bin size too high, like 1 ms bins, then the distribution of firing rates are very small. If I set it too high, the same problem occurs. Additionally, it seems like the firing rates are extremely high, which is why I wonder if the function is working properly.
4) I'd like to smooth my firing rate. I was using smoothdata(psth,'gaussian',window size) but I was wondering how to select a proper window size?
Any help would be much appreciated!
PAK

3 commentaires

If you're using code downloaded from file exchange, you are more likely to get a response if you post your question there.
For firing rates, bin widths of ~25-50ms are typical. Same for the smoothing kernel.
PAK
PAK le 5 Sep 2018
Hi Kaushik,
I will also post there. But in the meantime, would you be able to aid in the creation of a PSTH with overlapping bins like I've stated above?
Thanks for your suggestion!
PAK
Sorry, I haven't used that toolbox so I can't give specific suggestions. If you run into errors or need help with parts of the code, just post the relevant code along with the specific issue you're having.

Connectez-vous pour commenter.

Réponses (0)

Catégories

Produits

Version

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by