OSCR

Neural dynamics for working memory and evidence integration during olfactory navigation in Drosophila.

Code ↔ Paper

8 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 8 matches · 1 of them tie a paragraph to a whole file, not to given lines: a weak match, whose lines are not tinted
  1. [1] § Methods › Modeling persistent goal-directed navigation in an odor plume ↔ run_nav_simulation.m, lines 1–36 · score 0.87 · state behavioral model, neural dynamics, plume environment, odor concentration, odor signal, Transitions
  2. [2] § Methods › Data analysis › Analysis of neural encoding properties ↔ Kathman2026 Analysis and Plotting Code/Fig1hSup1jk-RegAnlys_bumpprebump_all_and_sep.m, lines 474–538 · score 0.67 · pre bump, Behavioral metrics, pre odor, post odor, duration
  3. [3] § Results › A persistent goal representation improves navigation in turbulent environments ↔ run_nav_simulation.m, lines 1–36 · score 0.63 · working memory, olfactory navigation, angular velocities, transition, agent, dynamics
  4. [4] § Methods › Experimental Paradigms › Software control ↔ Kathman2026 Analysis and Plotting Code/utilities/balldata_struct copy.m, lines 1–92 · score 0.60 · odor state, wind position, wind speed, Fictrac, timestamps
  5. [5] § Methods › Data analysis › Analysis of freely walking wind tunnel behavior data ↔ Kathman2026 Analysis and Plotting Code/Sup1bc-persistent_walking_ndk copy.m, lines 1–119 · score 0.59 · pass filtered, odor onset, odor offset, persistence, walking, heading
  6. [6] § Methods › Data analysis › Analysis of neural encoding properties ↔ Kathman2026 Analysis and Plotting Code/utilities/plottrials_flex copy.m, lines 532–647 · score 0.57 · minimum bump duration, bump onset, gaps, offset, threshold
  7. [7] § Methods › Data analysis › Processing of imaging data ↔ Kathman2026 Analysis and Plotting Code/utilities/analyzeCalciumExperiment_newThor5D copy.m, the whole file · a weak match · score 0.56 · register_rois2, imported, motion, correlated, frames
  8. [8] § Methods › Data analysis › Processing of walking ball data ↔ Kathman2026 Analysis and Plotting Code/Fig1gSup1i-bump_dur_dist.m, lines 185–236 · score 0.53 · confidence interval, Exponential, CI, decay, curves, fit

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 · 179 lines · 6 KB · GPL-3.0 · 2 matches

  1. function out = run_nav_simulation(triallength, tau, plot_figs)
  2. % RUN_NAV_SIMULATION Simulates odor-guided navigation based on neural dynamics
  3. %
  4. % out = run_nav_simulation(triallength, tau, plot_figs)
  5. %
  6. % This function simulates a Drosophila-like agent navigating within an odor
  7. % plume environment using a 3-state behavioral model (baseline, goal-directed,
  8. % search). The odor concentration is sampled from an external plume dataset
  9. % (Crimaldi 2017, 10 cm/s bounded plume).
  10. %
  11. % INPUTS:
  12. % triallength : number of samples to simulate (e.g. 1500 for ~100 s at fs=15 Hz)
  13. % tau : mean decay time constant (in seconds) controlling transition probability
  14. % plot_figs : logical (1 or 0), whether to display output figures
  15. %
  16. % OUTPUT:
  17. % out : structure with simulation results:
  18. % out.U - DN activity matrix (5 x time)
  19. % out.v - forward velocity (mm/s)
  20. % out.a - angular velocity (rad/s)
  21. % out.x - x position (plume pixel coordinates)
  22. % out.y - y position (plume pixel coordinates)
  23. % out.odor - sampled odor concentration
  24. % out.C - compressed odor signal
  25. % out.s - behavioral state index (1=baseline, 2=goal, 3=search)
  26. %
  27. % Example:
  28. % out = run_nav_simulation(1800, 5, 1);
  29. % This runs a 2-minute simulation with tau=5s and displays figures.
  30. %
  31. % Note:
  32. % You must edit the variable `plume_path` below to point to the correct
  33. % .h5 plume dataset on your system.
  34. %
  35. % Authors: Nicholas Kathman, Katherine Nagel (2025)
  36. % Manuscript: Neural dynamics for working memory and evidence integration during olfactory navigation in Drosophila
  37. %% 1. SETUP AND PARAMETERS
  38. % ---- Path to plume dataset (edit this path to your local copy) ----
  39. plume_path = '/path/to/10302017_10cms_bounded_2.h5'; % <-- update this line
  40. % ---- Simulation and model parameters ----
  41. beta = 0.025; % compression term
  42. thresh = 0.5; % odor detection threshold
  43. B = 0.8; % autocorrelation
  44. XLR = 0; % left-right weight (baseline)
  45. XLR2 = -0.035; % left-right weight (search)
  46. XS = -0.03; % stop weight
  47. XX = 0; % same-side DN interaction
  48. W = [B XX XS XLR XLR; XX B XS XLR XLR; XS XS B XS XS; XLR XLR XS B XX; XLR XLR XS XX B];
  49. Woff = [B XX XS XLR2 XLR2; XX B XS XLR2 XLR2; XS XS B XS XS; XLR2 XLR2 XS B XX; XLR2 XLR2 XS XX B];
  50. % Environment parameters (Crimaldi dataset)
  51. fs = 15; % Hz of plume video
  52. xpix = 216; ypix = 406; xmm = 159.84; ymm = 300.44;
  53. nsamp = 3600; % samples per plume dataset
  54. pxscale = xmm / xpix;
  55. % Behavioral coefficients and initial conditions
  56. avvars = [0.7 0.3 0.1 0.2]; % fitted from experimental data
  57. start_pos = [50, 0, 50, 300]; % [xrange, xoffset, yrange, yoffset]
  58. tauA = fs * 5; % adaptive odor time constant (samples)
  59. state = 'baseline'; % initial state
  60. U = [0.1; 0.1; 0; 0.1; 0.1]; % initial DN activity
  61. v(1) = 0; a(1) = 0; A(1) = 0; C(1) = 0;
  62. % Initial position and headin
  63. xrange = round(start_pos(1)*xpix/216);
  64. xoffset = round(start_pos(2)*xpix/216);
  65. yrange = round(start_pos(3)*ypix/406);
  66. yoffset = round(start_pos(4)*ypix/406);
  67. x(1) = randn(1)*xrange;
  68. y(1) = rand(1)*yrange - yoffset;
  69. theta(1) = 2*pi*rand(1);
  70. % Random noise and transition probability
  71. n = randn(5, triallength);
  72. p = 1 / (tau * fs); % convert decay time constant to probability
  73. %% 2. MAIN SIMULATION LOOP
  74. for i = 2:triallength
  75. tind = mod(i-1, nsamp) + 1; % restart plume sampling periodically
  76. xind = round(x(i-1)) + 108;
  77. yind = -round(y(i-1));
  78. % Sample odor intensity from plume dataset
  79. if ismember(xind, 1:216) && ismember(yind, 1:406)
  80. odor(i) = max(0, h5read(plume_path, '/dataset2', [xind yind tind], [1 1 1]));
  81. else
  82. odor(i) = 0;
  83. end
  84. % Adaptive odor compression
  85. A(i) = A(i-1) + (odor(i) - A(i-1)) / tauA;
  86. C(i) = round(odor(i) ./ (odor(i) + beta + A(i)));
  87. % Behavioral state updates
  88. switch state
  89. case 'baseline'
  90. s(i) = 1;
  91. U(:,i) = act(W*U(:,i-1) + 0.1*[1;1;0;-1;-1]*sin(theta(i-1)+pi/2) + n(:,i));
  92. if C(i) > thresh
  93. state = 'goal';
  94. end
  95. case 'goal'
  96. s(i) = 2;
  97. U(:,i) = act(W*U(:,i-1) + [1;1;0;-1;-1]*sin(theta(i-1)-pi/2) + [0;0;-.1;0;0] + n(:,i));
  98. if C(i) < thresh && rand(1) < p
  99. state = 'search';
  100. end
  101. case 'search'
  102. s(i) = 3;
  103. U(:,i) = act(Woff*U(:,i-1) + n(:,i));
  104. if C(i) > thresh
  105. state = 'goal';
  106. elseif rand(1) < 0.01
  107. state = 'baseline';
  108. end
  109. end
  110. % Compute motion
  111. if U(3,i) > 0
  112. v(i) = 0; a(i) = 0;
  113. else
  114. v(i) = (avvars(1)*max(0,sum(U([1 5],i))) + avvars(2)*max(0,sum(U([2 4],i))));
  115. a(i) = (avvars(3)*diff(U([1 5],i)) + avvars(4)*diff(U([2 4],i)));
  116. end
  117. theta(i) = theta(i-1) + a(i)/fs;
  118. [dx, dy] = pol2cart(theta(i), v(i)/fs);
  119. x(i) = x(i-1) + dx;
  120. y(i) = y(i-1) + dy;
  121. end
  122. %% 3. PLOTTING
  123. if plot_figs
  124. % Time series plots
  125. figure(1); set(gcf, 'Position', [78 34 367 751]);
  126. subplot(5,1,1); plot(odor); ylabel('odor');
  127. subplot(5,1,2); plot(C); ylabel('binary odor');
  128. subplot(5,1,3); hold off; plot(s==2,'r'); hold on; plot(s==3,'b'); ylabel('states');
  129. subplot(5,1,4); plot(v); ylabel('fvel');
  130. subplot(5,1,5); plot(a); ylabel('avel');
  131. % Trajectory plot
  132. figure(2); set(gcf, 'Position', [448 363 840 630]); hold on;
  133. plot(x, y, 'k');
  134. plot(x(s==1), y(s==1), 'k.');
  135. plot(x(s==2), y(s==2), 'c.');
  136. plot(x(s==3), y(s==3), 'g.');
  137. plot(x(1), y(1), 'xb', 'LineW', 6);
  138. plot([-107,108,108,-107,-107],[-405,-405,0,0,-405],'r-','LineWidth',3);
  139. plot([-107,0,108],[-405,0,-405],'r-','LineWidth',3);
  140. axis equal; xlabel('Crosswind (px)'); ylabel('Downwind (px)');
  141. end
  142. %% 4. OUTPUT STRUCTURE
  143. out.U = U;
  144. out.v = v;
  145. out.a = a;
  146. out.x = x;
  147. out.y = y;
  148. out.odor = odor;
  149. out.C = C;
  150. out.s = s;
  151. end
  152. %% HELPER FUNCTION
  153. function y = act(x)
  154. % Activation function preventing runaway excitation
  155. y = 20 ./ (1 + exp(-x/4)) - 10;
  156. end

run_nav_simulation.m at commit 371dc9d, under GPL-3.0 · at the source

Overview

  1. Department of Neuroscience, NYU School of Medicine,New York, NY USA
  2. Present Address: Department of Biological Sciences, Marshall University,Huntington, WV USA
Institutions: New York University (United States); Marshall University (United States)
Journal: Nature communications, volume 17, issue 1, article 9082
Dates: received 16 October 2025; accepted 16 July 2026; published online 25 July 2026
Type: Research article · Language: English
License: CC BY-NC-ND
Identifiers: DOI 10.1038/s41467-026-75945-2 · PMID 42649196 · PMCID PMC13518903 · OpenAlex W4403168484
Open access: gold, a free copy (OpenAlex)
Status: code verified
Categories: drosophila (organism), cognitive (subfield)
Methods: Spectral & time-frequency, Statistics, Evoked potentials, Connectivity, Graphs, fMRI & imaging, Single-unit activity, calcium imaging
Keywords: Olfactory system, Navigation
MeSH: Drosophila melanogaster*, Memory, Short-Term*, Neurons*, Smell*, Spatial Navigation*, Animals, Drosophila, Female, Odorants (* major topic)
Topic: Neurobiology and Insect Physiology Research (Cellular and Molecular Neuroscience, Neuroscience), according to OpenAlex
Funding: NINDS (NS127129); National Institute on Deafness and Other Communication Disorders (DC017979); NSF (NSF 2014217)
Citations: cited by 7 papers (Europe PMC); 64 references in the paper
Research resources: Primary antibodies were chicken anti-GFP RRID:AB_1074893, mouse anti-nc82 RRID:AB_2314866, RRID:AB_2534096, Alexa633-conjugated goat anti-mouse RRID:AB_2535719, Alexa568-conjugated goat anti-rabbit RRID:AB_2576217

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 8 matches between paragraphs and lines of code.

nagellab/AlvarezSalvado_ElementaryTransformations

License: MIT
State: the link answers, verified on 27 September 2026
Evidence: files inventoried
Commit: 46795a6c5b0228625fbecd1280a43f57ba3f0f39, 29 June 2018
Languages: MATLAB (35)
Size: 51 files, 35 scripts
Software Heritage: not archived
Found in: the text, “Analysis of freely walking wind tunnel behavior ”
Holds: README, license file
Not found: 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
37 files

nagellab/Mathesonetal2022

License: BSD-2-Clause
State: the link answers, verified on 27 September 2026
Evidence: files inventoried
Commit: 30bc47c0703527995af2a9d671bd2a1f32c1a29a, 5 July 2022
Languages: MATLAB (152), Java (1)
Size: 168 files, 153 scripts
Software Heritage: not archived
Found in: the text, “Analysis of freely walking wind tunnel behavior ”
Holds: README, license file
Not found: 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
155 files

nagellab/Kathmanetal2025

License: GPL-3.0
State: the link answers, verified on 27 September 2026
Evidence: files inventoried
Commit: 371dc9de7a26edb0de4ee79b077a09283ac3a2eb, 16 June 2026
Languages: MATLAB (44)
Size: 47 files, 44 scripts
Software Heritage: not archived
Found in: “Code availability”
Holds: README, license file
Not found: 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
46 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-75945-2.

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:

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

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

Recorded: type, language, journal, volume, issue, pages, dates, 4 authors, 2 keywords, 9 MeSH terms, 3 funders, 63 references, 5 RRIDs.

Cite

This paper

Kathman, N. D., Lanz, A. J., Freed, J. D., & Nagel, K. I. (2026). Neural dynamics for working memory and evidence integration during olfactory navigation in Drosophila. Nature communications, 17(1), 9082. https://doi.org/10.1038/s41467-026-75945-2

BibTeX

@article{kathman2026neural,
author = {Kathman, Nicholas D. and Lanz, Aaron J. and Freed, Jacob D. and Nagel, Katherine I.},
title = {{Neural dynamics for working memory and evidence integration during olfactory navigation in Drosophila}},
journal = {Nature communications},
year = {2026},
month = jul,
volume = {17},
number = {1},
pages = {9082},
publisher = {Nature Publishing Group},
issn = {2041-1723},
doi = {10.1038/s41467-026-75945-2},
url = {https://doi.org/10.1038/s41467-026-75945-2},
pmid = {42649196},
pmcid = {PMC13518903}
}

RIS

TY - JOUR
AU - Kathman, Nicholas D.
AU - Lanz, Aaron J.
AU - Freed, Jacob D.
AU - Nagel, Katherine I.
TI - Neural dynamics for working memory and evidence integration during olfactory navigation in Drosophila
T2 - Nature communications
J2 - Nat Commun
PY - 2026
DA - 2026/07/25
VL - 17
IS - 1
SP - 9082
SN - 2041-1723
PB - Nature Publishing Group
DO - 10.1038/s41467-026-75945-2
UR - https://doi.org/10.1038/s41467-026-75945-2
LA - en
ER -

CSL-JSON

{
"id": "10.1038/s41467-026-75945-2",
"type": "article-journal",
"title": "Neural dynamics for working memory and evidence integration during olfactory navigation in Drosophila",
"container-title": "Nature communications",
"author": [
{
"family": "Kathman",
"given": "Nicholas D."
},
{
"family": "Lanz",
"given": "Aaron J."
},
{
"family": "Freed",
"given": "Jacob D."
},
{
"family": "Nagel",
"given": "Katherine I."
}
],
"container-title-short": "Nat Commun",
"volume": "17",
"issue": "1",
"page": "9082",
"DOI": "10.1038/s41467-026-75945-2",
"PMID": "42649196",
"PMCID": "PMC13518903",
"ISSN": "2041-1723",
"publisher": "Nature Publishing Group",
"URL": "https://doi.org/10.1038/s41467-026-75945-2",
"language": "en",
"issued": {
"date-parts": [
[
2026,
7,
25
]
]
}
}

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.1126/sciadv.aeh7220 [code]
Central complex representations of self-movement are sufficient to compute wind direction in flight.
Journal: Science advances
In common: shadedErrorBar, Curve Fitting Toolbox, Image Processing Toolbox, 2 other tools, 13 references, author Katherine I Nagel
[2] doi:10.1038/s41586-026-10827-7 [code]
A vector-based strategy for olfactory navigation in Drosophila.
Journal: Nature
In common: drosophila, cognitive, 20 references
[3] doi:10.7554/elife.107589 [code]
Distinct evolutionary trajectories of two integration centres, the central complex and mushroom bodies, across Heliconiini butterflies.
Journal: eLife
In common: 10 references
[4] doi:10.1038/s41586-026-10735-w [code]
Distributed control circuits across a brain-and-cord connectome.
Journal: Nature
In common: drosophila, 8 references
[5] doi:10.3389/fnsys.2026.1822122 [code]
Convergence-divergence circuits for multimodal integration of innate and learned opponent valences.
Journal: Frontiers in systems neuroscience
In common: 8 references
[6] doi:10.1038/s41467-025-67545-3 [code]
Updating an allocentric goal from lateralised egocentric visual memories.
Journal: Nature communications
In common: Statistics and Machine Learning Toolbox, cognitive, 7 references
[7] doi:10.1038/s41467-026-72445-1 [code]
Perception and neural representation of intermittent odor stimuli in mice.
Journal: Nature communications
In common: 6 references
[8] doi:10.1093/cercor/bhag040 [code]
BOLD response delays represent local cortical processing.
Journal: Cerebral cortex (New York, N.Y. : 1991)
In common: fdr_bh (Benjamini-Hochberg FDR), shadedErrorBar, Curve Fitting Toolbox, 2 other tools, cognitive
[9] doi:10.1371/journal.pbio.3003938 [code]
Theta oscillations tag episodic memories for sleep-dependent consolidation.
Journal: PLoS biology
In common: fdr_bh (Benjamini-Hochberg FDR), shadedErrorBar, Image Processing Toolbox, 2 other tools, cognitive
[10] doi:10.1038/s41593-026-02357-2 [code]
Experience reorganizes content-specific memory traces in macaques.
Journal: Nature neuroscience
In common: fdr_bh (Benjamini-Hochberg FDR), Curve Fitting Toolbox, Image Processing Toolbox, 2 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.