Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a function to discretise spiketimes #454

Conversation

Kleinjohann
Copy link
Contributor

Adds a function to conversion.py which takes a SpikeTrain or a list of SpikeTrains as input and returns copies with discretised times.
This is useful for using spike_train_synchrony.Synchrotool with artificial spike trains which do not have a sampling rate, e.g. for Monte Carlo significance computations. It applies a sampling rate to those spike trains to make them resemble experimental spike trains recorded in a setup with an intrinsic sampling rate.

Additionally, add tests for the function
@coveralls
Copy link
Collaborator

coveralls commented Feb 21, 2022

Coverage Status

Coverage increased (+0.007%) to 88.622% when pulling f4fa0db on INM-6:feature/discretise_spiketrains into d0d3920 on NeuralEnsemble:master.

@Moritz-Alexander-Kern Moritz-Alexander-Kern added the new functionality New modules, functions label Feb 22, 2022
@Moritz-Alexander-Kern Moritz-Alexander-Kern added this to the v0.11.0 milestone Mar 2, 2022
Copy link
Member

@Moritz-Alexander-Kern Moritz-Alexander-Kern left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for contributing to elephant.
The proposed changes are optional, as they are not critical to functionality.

Unless otherwise declared, the acknowledged authors of this PR are:
kleinjohann

elephant/conversion.py Outdated Show resolved Hide resolved
elephant/conversion.py Show resolved Hide resolved
Kleinjohann and others added 2 commits March 8, 2022 12:20
Co-authored-by: Moritz Kern <92092328+Moritz-Alexander-Kern@users.noreply.github.com>
Co-authored-by: Moritz Kern <92092328+Moritz-Alexander-Kern@users.noreply.github.com>
@Kleinjohann
Copy link
Contributor Author

Thanks for contributing to elephant. The proposed changes are optional, as they are not critical to functionality.

Unless otherwise declared, the acknowledged authors of this PR are: kleinjohann

Looks good to me, thanks for the suggested improvements, I accepted and committed them.

@Moritz-Alexander-Kern Moritz-Alexander-Kern merged commit 0074a14 into NeuralEnsemble:master Mar 8, 2022
@Moritz-Alexander-Kern Moritz-Alexander-Kern mentioned this pull request Mar 9, 2022
1 task
@Moritz-Alexander-Kern Moritz-Alexander-Kern deleted the feature/discretise_spiketrains branch October 28, 2022 07:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new functionality New modules, functions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants