OSCR

Directional dynamics in the entorhinal cortex of male mice driven by behavioral constraints.

Code ↔ Paper

4 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 4 matches
  1. [1] § Methods › Pre-processing of 2-photon calcium signal ↔ packages/MCMC/utilities/get_next_spikes.m, lines 1–24 · score 0.65 · calcium transients, standard deviation, amplitude, signals, fluorescence, noise
  2. [2] § Methods › Pre-processing of 2-photon calcium signal ↔ packages/oasis/constrained_oasisAR1.m, lines 1–150 · score 0.57 · standard deviation, OASIS, baseline, signals, fluorescence, noise
  3. [3] § Methods › Correlation between cell pairs ↔ codes/imaging/calculate_cellpair_correlation_matrices.m, lines 7–50 · score 0.57 · correlation matrix, halves, Pearson, HDF, HDI, HDA
  4. [4] § Results › Population code reconfiguration ↔ codes/imaging/calculate_cellpair_correlation_matrices.m, lines 7–50 · score 0.55 · correlation matrix, HDI cells, halves, HDF, HDA, activity

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

MATLAB · 96 lines · 3.2 KB · no license · 2 matches

  1. % This code used to calculate cell-pair correlation matrices.
  2. % Used for Fig.2b-d
  3. clear;
  4. %%
  5. % load example data
  6. pth = fullfile('..','..','example_data');
  7. neuronactivity_of = load(fullfile(pth,'NeuronActivity_OF.mat')).NeuronActivity;
  8. neuronactivity_car = load(fullfile(pth,'NeuronActivity_CAR.mat')).NeuronActivity;
  9. behav_of = load(fullfile(pth,'behav_OF.mat')).behav;
  10. behav_car = load(fullfile(pth,'behav_CAR.mat')).behav;
  11. output_of = load(fullfile(pth,'output_OF.mat')).output;
  12. output_car = load(fullfile(pth,'output_CAR.mat')).output;
  13. fr_of = neuronactivity_of.Event_filtered_exp2;fr_of = fr_of>std(fr_of);
  14. fr_car = neuronactivity_car.Event_filtered_exp2;fr_car = fr_car>std(fr_car);
  15. hd_list = find(output_of.curMVL>0.44); % just for example, in Fig 2 we divided each session into two halves and use HDF/HDA/HDI cells
  16. fr_of = fr_of(:,hd_list); fr_car = fr_car(:,hd_list);
  17. % load peak direction during free condition
  18. pd = zeros(1,length(hd_list));
  19. for cellidx = 1:length(hd_list)
  20. stat_cell = output_of.tcStat{hd_list(cellidx)};
  21. pd(cellidx) = stat_cell.peakDirection;
  22. end
  23. % smooth in time
  24. gw=20;
  25. fr_of_smooth=cell2mat(arrayfun(@(z) mov_gauss1D(fr_of(:,z)',gw)',1:size(fr_of,2),'UniformOutput',0));
  26. fr_car_smooth=cell2mat(arrayfun(@(z) mov_gauss1D(fr_car(:,z)',gw)',1:size(fr_car,2),'UniformOutput',0));
  27. % reorder cells
  28. [~,indx]=sort(pd);
  29. fr_of_smooth=fr_of_smooth(:,indx);
  30. fr_car_smooth=fr_car_smooth(:,indx);
  31. % correlation matrices
  32. c_of=corr(fr_of_smooth,'Type','Pearson'); % correlation of spike train for each cell
  33. c_of(1:size(fr_of_smooth,2)+1:end)=nan;
  34. c_car=corr(fr_car_smooth,'Type','Pearson');
  35. c_car(1:size(fr_car_smooth,2)+1:end)=nan;
  36. % visualization
  37. subplot(121)
  38. imagesc(c_of);colormap('jet');
  39. caxis([min([c_of(:);c_car(:)]) max([c_of(:);c_car(:)])]);
  40. subplot(122)
  41. imagesc(c_car);colormap('jet');
  42. caxis([min([c_of(:);c_car(:)]) max([c_of(:);c_car(:)])]);
  43. %%
  44. % calculate in- vs. off-diagonal ratio
  45. % select nd elements around the diagonal and around the off diagonal
  46. N=size(fr_of_smooth,2);
  47. nd=max(1,round(N/20)); % select 10 % closest to/ furthest apart from the diagonal
  48. sel=false(N); seloff=sel;
  49. sel1=sel(:,1);
  50. sel1([2:1+nd N+1-nd:N])=true;
  51. sel1off=sel1([round(N/2)+1:N 1:round(N/2)]); % e.g. [16-29 1-15]
  52. for j=1:N
  53. sel(:,j)=sel1([N+2-j:N 1:N+1-j]);
  54. seloff(:,j)=sel1off([N+2-j:N 1:N+1-j]);
  55. end
  56. c_of = abs(c_of); c_car = abs(c_car);
  57. onoff_of = nanmean(c_of(sel(:)))/nanmean(c_of(seloff(:)));
  58. onoff_car = nanmean(c_car(sel(:)))/nanmean(c_car(seloff(:)));
  59. %%
  60. % calculate frobenius
  61. % normalization
  62. frob_of = c_of./nanmean(c_of,'all');
  63. frob_car = c_car./nanmean(c_car,'all');
  64. % calculate distance
  65. c_frobenius = [];
  66. for tempi1=1:N
  67. for tempi2=tempi1+1:N
  68. c_frobenius = [c_frobenius,(frob_of(tempi1,tempi2)-frob_car(tempi1,tempi2))^2];
  69. end
  70. end
  71. c_frobenius_session = nanmean(c_frobenius)
  72. % shuffle
  73. shuffletimes = 3; % just for example
  74. for shufi=1:shuffletimes
  75. rowrank=randperm(size(c_of,1));colrank=randperm(size(c_of,2));
  76. frob_of_shuf = frob_of(rowrank,colrank);
  77. c_frobenius_shuf = [];
  78. for tempi1=1:N
  79. for tempi2=tempi1+1:N
  80. c_frobenius_shuf = [c_frobenius_shuf,(frob_of_shuf(tempi1,tempi2)-frob_car(tempi1,tempi2))^2];
  81. end
  82. end
  83. end

calculate_cellpair_correlation_matrices.m at commit d88bc1f, no license · at the source

Overview

Authors: Ruojin Liu1,2,3, Jun Hao2,3,4, Xiang Zhang2,3, Shidan Wen2,3, Youran Yang1,2,3, Haiqian Cai1,2,3, Kai Gao1,2,3, Emilio Kropff5, Chenglin Miao1,2,3,6
  1. Peking-Tsinghua Center for Life Sciences, Beijing, China
  2. PKU-IDG/McGovern Institute for Brain Research, Peking university, Beijing, China
  3. State Key Laboratory of Membrane Biology, School of Life Science, Peking university, Beijing, China
  4. Present Address: School of Life Sciences, Westlake University, Hangzhou, China
  5. Leloir Institute/IIBBA-CONICET, Buenos Aires, Argentina
  6. Chinese Institute for Brain Research (CIBR), Beijing, China
Journal: Nature communications, volume 17, issue 1, article 3679
Dates: received 11 May 2025; accepted 24 February 2026; published online 9 March 2026
Type: Research article · Language: English
License: CC BY-NC-ND
Identifiers: DOI 10.1038/s41467-026-70289-3 · PMID 41803123 · PMCID PMC13099953 · OpenAlex W7134254680
Open access: gold, a free copy (OpenAlex)
Status: code verified
Categories: mouse (organism), systems (subfield)
Methods: Connectivity, Statistics, Machine learning, Preprocessing, Evoked potentials, fMRI & imaging, Single-unit activity, calcium imaging
Keywords: Cortex, Spatial memory
MeSH: Behavior, Animal*, Entorhinal Cortex*, Neurons*, Animals, Male, Mice, Mice, Inbred C57BL (* major topic)
Topic: Memory and Neural Mechanisms (Cognitive Neuroscience, Neuroscience), according to OpenAlex
Citations: not cited yet (Europe PMC); 70 references in the paper

Abstract

The abstract is not reproduced here: the paper's license (CC BY-NC-ND) does not allow it. Read it in the paper, at the publisher or on Europe PMC.

Repositories

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

zhoupc/OASIS_matlab

License: GPL-3.0
State: the link answers, verified on 30 September 2026
Evidence: files inventoried
Commit: 6f42ebd0e2cbbbeeb2a73c537d2e02a54f5f34fc, 22 October 2020
Languages: MATLAB (851), C (71), JavaScript (9), C/C++ (4)
Size: 1,474 files, 935 scripts
Software Heritage: not archived
Found in: the text, “Pre-processing of 2-photon calcium signal”
Holds: README, license file, documentation
Not found: CITATION.cff, environment file, tests, continuous integration
Availability: 1 check, the latest on 30 September 2026: the link answers
  • 30 September 2026: the link answers
937 files

RuojinLiu/assisted_movement

License: none: the authors keep all their rights
State: the link answers, verified on 30 September 2026
Evidence: files inventoried
Commit: d88bc1f23a139bbb23ba91218b8cb69a5c411625, 21 October 2025
Languages: MATLAB (10)
Size: 13 files, 10 scripts
Software Heritage: not archived
Found in: “Code availability”
Holds: README, 1 notebook
Not found: license file, CITATION.cff, environment file, tests, continuous integration, documentation
Availability: 1 check, the latest on 30 September 2026: the link answers
  • 30 September 2026: the link answers
11 files

Code availability statement

The paper has a code availability statement. Its license (CC BY-NC-ND) does not allow reproducing it here; in short, from what the harvester recognized in it:

Read it in the paper: doi.org/10.1038/s41467-026-70289-3.

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:

  • 2 repositories of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 945 scripts, each with its path and the digest of its content;
  • 4 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 statement

The paper has a data availability statement. Its license (CC BY-NC-ND) does not allow reproducing it here; in short, from what the harvester recognized in it:

Read it in the paper: doi.org/10.1038/s41467-026-70289-3.

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, 30 September 2026: the first record

Recorded: type, language, journal, volume, issue, pages, dates, 9 authors, 2 keywords, 7 MeSH terms, 66 references.

Cite

This paper

Liu, R., Hao, J., Zhang, X., Wen, S., Yang, Y., Cai, H., Gao, K., Kropff, E., & Miao, C. (2026). Directional dynamics in the entorhinal cortex of male mice driven by behavioral constraints. Nature communications, 17(1), 3679. https://doi.org/10.1038/s41467-026-70289-3

BibTeX

@article{liu2026directional,
author = {Liu, Ruojin and Hao, Jun and Zhang, Xiang and Wen, Shidan and Yang, Youran and Cai, Haiqian and Gao, Kai and Kropff, Emilio and Miao, Chenglin},
title = {{Directional dynamics in the entorhinal cortex of male mice driven by behavioral constraints}},
journal = {Nature communications},
year = {2026},
month = mar,
volume = {17},
number = {1},
pages = {3679},
publisher = {Nature Publishing Group},
issn = {2041-1723},
doi = {10.1038/s41467-026-70289-3},
url = {https://doi.org/10.1038/s41467-026-70289-3},
pmid = {41803123},
pmcid = {PMC13099953}
}

RIS

TY - JOUR
AU - Liu, Ruojin
AU - Hao, Jun
AU - Zhang, Xiang
AU - Wen, Shidan
AU - Yang, Youran
AU - Cai, Haiqian
AU - Gao, Kai
AU - Kropff, Emilio
AU - Miao, Chenglin
TI - Directional dynamics in the entorhinal cortex of male mice driven by behavioral constraints
T2 - Nature communications
J2 - Nat Commun
PY - 2026
DA - 2026/03/09
VL - 17
IS - 1
SP - 3679
SN - 2041-1723
PB - Nature Publishing Group
DO - 10.1038/s41467-026-70289-3
UR - https://doi.org/10.1038/s41467-026-70289-3
LA - en
ER -

CSL-JSON

{
"id": "10.1038/s41467-026-70289-3",
"type": "article-journal",
"title": "Directional dynamics in the entorhinal cortex of male mice driven by behavioral constraints",
"container-title": "Nature communications",
"author": [
{
"family": "Liu",
"given": "Ruojin"
},
{
"family": "Hao",
"given": "Jun"
},
{
"family": "Zhang",
"given": "Xiang"
},
{
"family": "Wen",
"given": "Shidan"
},
{
"family": "Yang",
"given": "Youran"
},
{
"family": "Cai",
"given": "Haiqian"
},
{
"family": "Gao",
"given": "Kai"
},
{
"family": "Kropff",
"given": "Emilio"
},
{
"family": "Miao",
"given": "Chenglin"
}
],
"container-title-short": "Nat Commun",
"volume": "17",
"issue": "1",
"page": "3679",
"DOI": "10.1038/s41467-026-70289-3",
"PMID": "41803123",
"PMCID": "PMC13099953",
"ISSN": "2041-1723",
"publisher": "Nature Publishing Group",
"URL": "https://doi.org/10.1038/s41467-026-70289-3",
"language": "en",
"issued": {
"date-parts": [
[
2026,
3,
9
]
]
}
}

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/s41467-026-72620-4 [code]
Grid maps are disrupted after large-scale arena expansion and recover with experience.
Journal: Nature communications
In common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, systems, mouse, 8 references
[2] doi:10.1038/s41467-026-72453-1 [code]
The entorhinal spatial map integrates visual identity information of landmarks.
Journal: Nature communications
In common: Statistics and Machine Learning Toolbox, mouse, 7 references
[3] 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, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, systems, mouse, 3 references
[4] doi:10.1038/s41467-026-71503-y [code]
Rapid formation of non-spatial hippocampal representations consistent with behavioral timescale synaptic plasticity is modulated by entorhinal input.
Journal: Nature communications
In common: Optimization Toolbox, Image Processing Toolbox, Statistics and Machine Learning Toolbox, mouse, 3 references
[5] doi:10.1080/26941899.2026.2619222
Neurodatascience: Past, Present, and Future.
Journal: Data science in science
In common: 6 references
[6] doi:10.64898/2026.03.10.710908 [code]
Toroidal topology of grid-cell activity precedes spatial navigation during development
Journal: bioRxiv (preprint)
In common: Image Processing Toolbox, Signal Processing Toolbox, Statistics and Machine Learning Toolbox, 3 references
[7] doi:10.1371/journal.pcbi.1014577 [code]
Combining sampling and attractor dynamics in spiking models of head direction systems.
Journal: PLoS computational biology
In common: mouse, 5 references
[8] doi:10.1016/j.celrep.2026.117646 [code]
Medial entorhinal-hippocampal desynchronization parallels the emergence of memory impairment in a mouse model of Alzheimer's disease pathology.
Journal: Cell reports
In common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, systems, mouse, 1 reference
[9] doi:10.1126/sciadv.aea1037 [code]
Distinct cortical spatial representations learned along disparate visual pathways.
Journal: Science advances
In common: Image Processing Toolbox, Signal Processing Toolbox, Statistics and Machine Learning Toolbox, systems, 2 references
[10] doi:10.1016/j.cub.2026.05.068 [code]
An abstract relational map emerges in the human medial prefrontal cortex with consolidation.
Journal: Current biology : CB
In common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, systems, 1 reference

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.