OSCR

Neural circuits encode prior knowledge of temporal statistics.

Code ↔ Paper

13 matches between paragraphs of the paper and lines of its authors' code, computed by the harvester (lexical-v1). Click a colored paragraph or line to see its counterpart.

The 13 matches · 5 of them tie a paragraph to a whole file, not to given lines: weak matches, whose lines are not tinted
  1. [1] § Methods › Optogenetics › Single-unit isolation pipeline, cell type identification, modulation and contamination checks ↔ src/lussac/modules/find_purkinje_cells.py, lines 10–77 · score 0.70 · cross correlogram, Purkinje cells, complex spike, firing rate, putative, properties
  2. [2] § Methods › Optogenetics › Functional classification of cerebellar cortical population ↔ src/lussac/modules/find_purkinje_cells.py, lines 10–77 · score 0.63 · spiking activity, simple spiking, Purkinje cell, firing rates, ms, baseline
  3. [3] § Methods › Quantification of eyeblink metrics ↔ Trace/BehavioralAnalysis/BlinkAnalysis_v2.m, lines 369–420 · score 0.63 · eye closure, peak velocity, speed, rise, eyelid, threshold
  4. [4] § Methods › Optogenetics › Functional classification of cerebellar cortical population ↔ zetatest.m, lines 1–132 · score 0.63 · window length, window relative, precision, firing rates, ZETA, onset
  5. [5] § Methods › Quantification of eyeblink metrics ↔ BehavioralAnalysis/ShortAnalysis.m, the whole file · a weak match · score 0.61 · CR amplitude, CR percentage, peak velocity, rise, threshold, AUC
  6. [6] § Results › Predictive eyelid behavior modulates with changes in temporal statistics ↔ BehavioralAnalysis/DeltaUniformShortAnalysis.m, lines 27–167 · score 0.57 · Short experts, error bars, peak velocity, uniform, ms, amplitude
  7. [7] § Methods › Optogenetics › Single-unit isolation pipeline, cell type identification, modulation and contamination checks ↔ src/lussac/modules/export_to_phy.py, the whole file · a weak match · score 0.57 · refractory period, violations, Phy, waveforms, contamination, channel
  8. [8] § Results › A novel Purkinje cell CSpk signal encoding onset of prior distribution ↔ zetatest.m, lines 1–132 · score 0.55 · instantaneous firing rate, event onset, locked, latency, cross, Width
  9. [9] § Results › Cerebellar cortical activity changes concomitantly with temporal statistics and behavior ↔ BehavioralAnalysis/ShortAnalysis.m, the whole file · a weak match · score 0.55 · error bars, peak velocity, switch mice, Ave, AUC, metrics
  10. [10] § Methods › Trial-by-trial analysis of neural activity using LFADS ↔ ephys/lfads/+analysis/detectCrAmp.m, lines 1–86 · score 0.52 · LFADS models, terminated, smooth, training, activity, traces
  11. [11] § Methods › Mice and surgical setup ↔ ephys/spikeSorting/+SessionStitching/JK_AlignmentAndBehavior_sessionStitching.m, the whole file · a weak match · score 0.51 · Erasmus Medical Center, setup, switch, behavioral
  12. [12] § Methods › Analysis of Purkinje cell and pMLI populations ↔ SHARP-Track/Display_Probe_Track.m, lines 104–214 · score 0.51 · largest eigenvalues, eigenvectors, dimensional
  13. [13] § Methods › Mice and surgical setup ↔ +JkUtils/findPlateau.m, the whole file · a weak match · score 0.51 · Erasmus Medical Center, min

Paper

Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC

The paper is loaded when this pane is shown.

The authors' code

Python · 77 lines · 3.3 KB · AGPL-3.0 · 2 matches

  1. from typing import Any
  2. import numpy as np
  3. from overrides import override
  4. from lussac.core import MonoSortingModule
  5. import spikeinterface.core as si
  6. import spikeinterface.postprocessing as spost
  7. import spikeinterface.metrics as sm
  8. class FindPurkinjeCells(MonoSortingModule):
  9. """
  10. This module is meant purely for the cerebellar cortex.
  11. Purkinje cells are big GABAergic neurons that can fire both simple spikes and complex spikes.
  12. Since simple spikes and complex spikes have different shape, they will be clustered in different units.
  13. This module will find simple spikes and complex spikes coming from the same Purkinje cell,
  14. and label then into a 'lussac_purkinje' property in the sorting object.
  15. This is done by looking at the cross-correlogram between the two units: after a complex spike,
  16. there is always a pause of at least 8-10 ms before simple spike activity resumes.
  17. Also, when high-pass filtered aggressively, the templates are nearly identical.
  18. """
  19. @property
  20. @override
  21. def default_params(self) -> dict[str, Any]:
  22. return {
  23. 'cross_corr_pause': [0.0, 8.0],
  24. 'threshold': 0.4,
  25. 'ss_min_fr': 40.0,
  26. 'cs_min_fr': 0.5,
  27. 'cs_max_fr': 3.0
  28. }
  29. @override
  30. def update_params(self, params: dict[str, Any]) -> dict[str, Any]:
  31. params = super().update_params(params)
  32. if params['ss_min_fr'] <= params['cs_max_fr']:
  33. raise ValueError("Error in 'find_purkinje_cells': 'ss_min_fr' must be greater than 'cs_max_fr'")
  34. if params['threshold'] < 0.0:
  35. raise ValueError("Error in 'find_purkinje_cells': 'threshold' cannot be negative")
  36. return params
  37. @override
  38. def run(self, params: dict[str, Any]) -> si.BaseSorting:
  39. analyzer = si.SortingAnalyzer.create(self.sorting, self.recording)
  40. firing_rates = sm.compute_firing_rates(analyzer)
  41. putative_ss_units = [unit_id for unit_id, mean_fr in firing_rates.items() if mean_fr >= params['ss_min_fr']]
  42. putative_cs_units = [unit_id for unit_id, mean_fr in firing_rates.items() if params['cs_min_fr'] <= mean_fr <= params['cs_max_fr']]
  43. sorting = self.sorting.select_units([*putative_ss_units, *putative_cs_units])
  44. correlograms, bins = spost.compute_correlograms(sorting, window_ms=25.0, bin_ms=1.0, method="numba")
  45. mask = ((bins >= params['cross_corr_pause'][0]) & (bins < params['cross_corr_pause'][1]))[:-1]
  46. ss_cs_pairs = []
  47. for ss_id in putative_ss_units:
  48. for cs_id in putative_cs_units:
  49. ss_ind = sorting.id_to_index(ss_id)
  50. cs_ind = sorting.id_to_index(cs_id)
  51. cross_corr = correlograms[ss_ind, cs_ind, :]
  52. baseline = np.median(cross_corr[bins[:-1] < 0.0])
  53. if np.median(cross_corr[mask]) < baseline * params['threshold']: # Check for pause.
  54. if np.median(cross_corr[mask[::-1]] < baseline * params['threshold']): # Check for asymmetry.
  55. continue
  56. ss_cs_pairs.append((ss_id, cs_id)) # TODO: Also check templates?
  57. lussac_purkinje = np.empty(self.sorting.get_num_units(), dtype=object)
  58. paired_units = np.unique(np.array(ss_cs_pairs).flatten())
  59. for unit_id in paired_units:
  60. unit_ind = self.sorting.id_to_index(unit_id)
  61. mask = np.array([unit_id in ss_cs_pairs[i] for i in range(len(ss_cs_pairs))])
  62. text = " ; ".join([f"{ss_id}-{cs_id}" for ss_id, cs_id in np.array(ss_cs_pairs)[mask]])
  63. lussac_purkinje[unit_ind] = text
  64. self.sorting.set_property('lussac_purkinje', lussac_purkinje)
  65. return self.sorting

find_purkinje_cells.py at commit 2a0dce1, under AGPL-3.0 · at the source

Overview

Authors: Julius Koppen1,2, Ilse Klinkhamer2, Marit Runge2, Lucas Bayones2,3, Devika Narain1,2
  1. Donders Center for Neuroscience, Donders Institute, Radboud University, Nijmegen, The Netherlands
  2. Department of Neuroscience, Erasmus University Medical Center, Rotterdam, The Netherlands
  3. Instituto de Fisiología Celular, Departamento de Neurociencia Cognitiva, Universidad Nacional Autónoma de México, Mexico City, Mexico
Journal: Nature neuroscience, volume 29, issue 6, pages 1452-1461
Dates: received 24 June 2025; accepted 4 March 2026; published online 7 April 2026; in print 2026
Type: Research article · Language: English
License: CC BY
Identifiers: DOI 10.1038/s41593-026-02255-7 · PMID 41946969 · PMCID PMC13246449 · OpenAlex W7151356605
Open access: hybrid, a free copy (OpenAlex)
Status: code verified
Categories: mouse (organism), systems (subfield)
Methods: Smoothing, state filtering, decompositions, Machine learning, Statistics, fMRI & imaging, Single-unit activity, calcium imaging, Physiology & signal measures
Keywords: Classical conditioning, Neural circuits, Cognitive neuroscience
MeSH: Cerebellum*, Conditioning, Eyelid*, Learning*, Nerve Net*, Purkinje Cells*, Action Potentials, Animals, Bayes Theorem, Male, Mice, Mice, Inbred C57BL, Models, Neurological, Neural Pathways (* major topic)
Topic: Vestibular and auditory disorders (Neurology, Neuroscience), according to OpenAlex
Funding: Dutch Research Council (NWO) (Vidi-VI.193.076)
Citations: cited by 3 papers (Europe PMC); 80 references in the paper

Abstract

The brain must infer the state of the external world despite the inherent uncertainty of its sensory inputs and internal processes. Under conditions of heightened uncertainty, it increasingly relies on prior knowledge, derived from accumulated experience with the regularities and statistical structures of the environment. This principle has been formalized by Bayesian inference theories, which are supported by substantial evidence from both behavioral and neuroscience studies. However, direct evidence for the existence of prior knowledge in the brain, and for the encoding of environmental statistics by neural circuits, remains limited. Here we show that cerebellar circuits learn the prior probability distribution of temporal variables during eyeblink conditioning in mice and encode these representations in Purkinje cell simple and complex spike signaling. We further demonstrate that Purkinje cells are involved in eliciting predictive motor behaviors, such as the conditioned eyeblink response, that also reflect the statistics of the experimentally imposed prior distribution of the stimulus. Computational modeling of these results indicates the juxtaposition of counteracting long-term plasticity mechanisms by which cerebellar Purkinje cells could acquire prior knowledge that is shaped by the statistics of different probability distributions. Our results suggest that the cerebellar circuitry may be uniquely poised to learn the probability of events in the world and internalize these as prior knowledge. These findings advance understanding of how neural computations could implement Bayesian inference.

Reproduced under the paper's license (CC BY), from the paper cited above.

Repositories

Its files are read in the Code ↔ Paper reader above, with 13 matches between paragraphs and lines of code.

JorritMontijn/zetatest

License: GPL-3.0
State: the link answers, verified on 29 September 2026
Evidence: files inventoried
Commit: 1b7a1ee05726046706d89e5ea386d90aac0f6d87, 7 July 2026
Languages: MATLAB (57), Python (5), C (2)
Size: 87 files, 64 scripts
Software Heritage: not archived
Found in: “Code availability”
Holds: README, license file, environment (latenzy/python/requirements.txt, latenzy/python/setup.py), continuous integration
Not found: CITATION.cff, tests, documentation
Tools: Statistics and Machine Learning Toolbox (14 files), Parallel Computing Toolbox (8 files), NumPy (4 files), SciPy (3 files), Signal Processing Toolbox (1 file), Matplotlib (1 file)
Availability: 1 check, the latest on 29 September 2026: the link answers
  • 29 September 2026: the link answers
66 files

BarbourLab/lussac

License: AGPL-3.0
State: the link answers, verified on 29 September 2026
Evidence: files inventoried
Commit: 2a0dce18ca9fd6f9d275b2e9dcba9fdcf588e83e, 27 July 2026
Languages: Python (50), Jupyter (5)
Size: 77 files, 55 scripts
Software Heritage: not archived
Found in: “Code availability”
Holds: README, license file, environment (pyproject.toml), tests, continuous integration, documentation, 3 notebooks
Not found: CITATION.cff
Tools: SpikeInterface (36 files), NumPy (30 files), Plotly (11 files), NetworkX (7 files), pandas (7 files), Numba (3 files), SciPy (3 files), MountainSort (2 files), MNE-Python (1 file), scikit-learn (1 file)
Availability: 1 check, the latest on 29 September 2026: the link answers
  • 29 September 2026: the link answers
57 files

cortex-lab/allenCCF

License: none: the authors keep all their rights
State: the link answers, verified on 27 September 2026
Evidence: files inventoried
Commit: e5a57fe7e1c9fb333fec51c29a8471131c233a76, 15 July 2025
Languages: MATLAB (61)
Size: 75 files, 61 scripts
Software Heritage: not archived
Found in: “Code availability”
Holds: README
Not found: license file, CITATION.cff, environment file, tests, continuous integration, documentation
Availability: 1 check, the latest on 27 September 2026: the link answers
  • 27 September 2026: the link answers
62 files

Zenodo 18434825

License: MIT
State: the link answers, verified on 29 September 2026
Evidence: files inventoried
Size: 1 file
Software Heritage: not checked
Found in: the references
Not found: README, license file, CITATION.cff, environment file, tests, continuous integration, documentation
Availability: 1 check, the latest on 29 September 2026: the link answers (HTTP 200)
  • 29 September 2026: the link answers (HTTP 200)
935 files

narainneuro/koppenetal2026

License: MIT
State: the link answers, verified on 29 September 2026
Evidence: files inventoried
Commit: ccc75e052026512dae57c56bd8a4ad3407cee8f5, 29 January 2026
Languages: MATLAB (931), C (3)
Size: 969 files, 934 scripts
Software Heritage: not archived
Found in: the Zenodo archive record
Holds: license file
Not found: README, CITATION.cff, environment file, tests, continuous integration, documentation
Availability: 1 check, the latest on 29 September 2026: the link answers
  • 29 September 2026: the link answers
935 files

Code availability

The code developed for this study is provided on Zenodo80. Open-access code of methods that we used to different extents can be found here: (1) Kilosort version 2.0 and Phy version 2.0 (https://github.com/MouseLand/Kilosort/releases/tag/v2.0, https://github.com/cortex-lab/phy/ releases/tag/v2.0a1); (2) LFADS (https://lfads.github.io/lfads-run-manager/releases/tag/v0.3.1); (3) Zeta (https://github.com/JorritMontijn/zetatest/ releases/tag/v3.1.5); (4) C4 (https://github.com/m-beau/NeuroPyxels/tree/cell_types_classifier/tree/bcbae4ce26a91e1bb1f006954d763790eca65f72); (5) Lussac 2.0 (https://github.com/BarbourLab/lussac/releases/tag/v2.0rc5); and (6) Allen Common Coordinate Framework (https://github.com/cortex-lab/allenCCF/tree/9d21d8cd2fa982b959b26db528851d3bb9af57c1).

Reproduced under the paper's license (CC BY), from the paper cited above.

Tracing map

Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.

What the map holds:

  • 5 repositories of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 2,048 scripts, each with its path and the digest of its content;
  • 13 matches between paragraphs of the paper and lines of the code (method lexical-v1);
  • neither the text of the paper nor the code itself.

Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.

Data

Datasets cited

Data availability

Data generated in this study have been deposited in the Dryad database (10.5061/dryad.q573n5tz1).

Reproduced under the paper's license (CC BY), from the paper cited above.

Versions

The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.

Version 1, 29 September 2026: the first record

Recorded: type, language, journal, volume, issue, pages, dates, 5 authors, 3 keywords, 13 MeSH terms, 1 funder, 74 references.

Cite

This paper

Koppen, J., Klinkhamer, I., Runge, M., Bayones, L., & Narain, D. (2026). Neural circuits encode prior knowledge of temporal statistics. Nature neuroscience, 29(6), 1452-1461. https://doi.org/10.1038/s41593-026-02255-7

BibTeX

@article{koppen2026neural,
author = {Koppen, Julius and Klinkhamer, Ilse and Runge, Marit and Bayones, Lucas and Narain, Devika},
title = {{Neural circuits encode prior knowledge of temporal statistics}},
journal = {Nature neuroscience},
year = {2026},
month = apr,
volume = {29},
number = {6},
pages = {1452--1461},
publisher = {Nature Portfolio},
issn = {1097-6256},
doi = {10.1038/s41593-026-02255-7},
url = {https://doi.org/10.1038/s41593-026-02255-7},
pmid = {41946969},
pmcid = {PMC13246449}
}

RIS

TY - JOUR
AU - Koppen, Julius
AU - Klinkhamer, Ilse
AU - Runge, Marit
AU - Bayones, Lucas
AU - Narain, Devika
TI - Neural circuits encode prior knowledge of temporal statistics
T2 - Nature neuroscience
J2 - Nat Neurosci
PY - 2026
DA - 2026/04/07
VL - 29
IS - 6
SP - 1452
EP - 1461
SN - 1097-6256
PB - Nature Portfolio
DO - 10.1038/s41593-026-02255-7
UR - https://doi.org/10.1038/s41593-026-02255-7
LA - en
ER -

CSL-JSON

{
"id": "10.1038/s41593-026-02255-7",
"type": "article-journal",
"title": "Neural circuits encode prior knowledge of temporal statistics",
"container-title": "Nature neuroscience",
"author": [
{
"family": "Koppen",
"given": "Julius"
},
{
"family": "Klinkhamer",
"given": "Ilse"
},
{
"family": "Runge",
"given": "Marit"
},
{
"family": "Bayones",
"given": "Lucas"
},
{
"family": "Narain",
"given": "Devika"
}
],
"container-title-short": "Nat Neurosci",
"volume": "29",
"issue": "6",
"page": "1452-1461",
"DOI": "10.1038/s41593-026-02255-7",
"PMID": "41946969",
"PMCID": "PMC13246449",
"ISSN": "1097-6256",
"publisher": "Nature Portfolio",
"URL": "https://doi.org/10.1038/s41593-026-02255-7",
"language": "en",
"issued": {
"date-parts": [
[
2026,
4,
7
]
]
}
}

The tracing map gets a citation of its own once an author has validated it and it has a DOI.

Similar papers

The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.

[1] doi:10.1038/s41593-026-02232-0 [code]
Entorhinal cortex represents task-relevant remote locations independently of CA1.
Journal: Nature neuroscience
In common: SpikeInterface, Optimization Toolbox, Numba, 9 other tools, systems, mouse, 1 reference
[2] doi:10.1016/j.neuron.2026.03.034 [code]
Dentate gyrus interneurons modulate winner-take-all network dynamics in freely behaving mice.
Journal: Neuron
In common: shadedErrorBar, Optimization Toolbox, Parallel Computing Toolbox, 9 other tools, systems, mouse
[3] doi:10.7554/elife.110588 [code]
Opening the black box toward a modular approach to spike sorting.
Journal: eLife
In common: MountainSort, SpikeInterface, Numba, 6 other tools, mouse, 1 reference
[4] doi:10.1126/sciadv.aed6417 [code]
Intrinsic timing, not temporal prediction, underlies ramping dynamics in visual and parietal cortex during passive behavior.
Journal: Science advances
In common: Plotly, scikit-learn, pandas, 3 other tools, systems, mouse, 5 references
[5] doi:10.1016/j.patter.2026.101590 [code]
Density-based longitudinal neuron tracking in high-density electrophysiological recordings.
Journal: Patterns (New York, N.Y.)
In common: SpikeInterface, shadedErrorBar, Optimization Toolbox, 8 other tools
[6] doi:10.1038/s41467-026-75347-4 [code]
Sleep reveals dynamics integrating and segregating movement and stimulus representations in V1.
Journal: Nature communications
In common: Optimization Toolbox, Numba, Parallel Computing Toolbox, 8 other tools, systems, mouse
[7] doi:10.1038/s42003-026-10957-8 [code]
Brain defence by the extracellular matrix protein Cochlin.
Journal: Communications biology
In common: Optimization Toolbox, Numba, NetworkX, 8 other tools, mouse
[8] doi:10.1126/sciadv.aeh7220 [code]
Central complex representations of self-movement are sufficient to compute wind direction in flight.
Journal: Science advances
In common: shadedErrorBar, Optimization Toolbox, Parallel Computing Toolbox, 8 other tools
[9] doi:10.1016/j.celrep.2026.117420 [code]
Neural population dynamics of direct electrical stimulation of neocortex.
Journal: Cell reports
In common: Open Ephys analysis tools, NetworkX, scikit-learn, 4 other tools, systems, mouse, 3 references
[10] doi:10.1093/sleep/zsag168 [code]
Deltas' and spindles' cross-area synchronization and ripple subtypes.
Journal: Sleep
In common: Open Ephys analysis tools, Parallel Computing Toolbox, Plotly, 7 other tools

Contribute

The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.

Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.

Request its removal

To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).

Discussion, reproductions, activity

Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.

Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.

Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.