Skip to content

Conversation

@pas-calc
Copy link

see #538

@pas-calc pas-calc requested a review from gviejo as a code owner January 13, 2026 16:30
@gviejo
Copy link
Contributor

gviejo commented Jan 13, 2026

Guidelines for contributing is shown here : https://github.com/pynapple-org/pynapple/blob/main/CONTRIBUTING.md
You can write the tests in tests/test_tuning_curves.py.
Thanks

@wulfdewolf
Copy link
Collaborator

I like the idea of this!
The sparsity score is indeed nice to have, and easily computed from the tuning curves.
The function you wrote seems good.

For us to merge this though we will need:

  • comprehensive testing
  • docstring examples

As we have for the mutual information function.

The fasted way will be if you write these!
I can also do it, but have other priorities for the moment, so that route will take longer.

@pas-calc
Copy link
Author

I like the idea of this! The sparsity score is indeed nice to have, and easily computed from the tuning curves. The function you wrote seems good.

For us to merge this though we will need:

* comprehensive testing

* docstring examples

As we have for the mutual information function.

The fasted way will be if you write these! I can also do it, but have other priorities for the moment, so that route will take longer.

Yes I will have a go on that

Added an example to demonstrate how to compute the sparsity of a neuron's tuning curve using synthetic data.
@pas-calc pas-calc closed this Jan 21, 2026
@pas-calc pas-calc deleted the patch-1 branch January 21, 2026 10:47
@pas-calc pas-calc restored the patch-1 branch January 21, 2026 10:48
@pas-calc pas-calc reopened this Jan 21, 2026
@gviejo
Copy link
Contributor

gviejo commented Jan 30, 2026

Hello you can lint the project with black pynapple after installing the right version pip install black==26.1.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants