Course project · neural data analysis

Event identity, point-process GLMs, and a putative inhibitory link

A compact re-analysis of mouse spike recordings from a virtual odor–context task: first, ask whether a neuron carries identity-specific task-event information; then test whether that evidence supports a simple inhibitory story about a second neuron.

In each trial, a mouse traversed a visual corridor and entered one of two contexts. An odor puff followed after context entry, at the animal’s first inhalation. Water was available in the reward zone only for the rewarded-odor / rewarded-context combination (OR + CR), contingent on licking; OR + CU, OU + CR, and OU + CU were not rewarded. The analyses below use those four odor–context combinations.

NeurosciencePoint-process GLMStatistical modeling
Code and reproducibility
Paper and data

This analysis is based on the recordings described in Federman et al., Nature Communications (2024). The repository contains the analysis code and documentation, but does not redistribute the neural recordings. To reproduce the analysis with the original data, contact the corresponding authors through the paper’s data-availability route. The paper also links the authors’ source-data record.

The original authors’ Matlab GLM implementation is available at marinburginlab/olfactionGLM.

Two units, one tempting visual story

Neuron 45 reduces its firing during the task, particularly in OR + CR. Neuron 52 shows a pronounced task-locked response. This makes the pair interesting, but opposite-looking averages are not evidence that 52 inhibits 45: both responses may simply reflect the same task structure at different times.

Neuron 45, aligned to first odor inhalation
Raster and firing-rate traces for neuron 45 across four odor and context conditions, aligned at first odor inhalation.
Neuron 52, aligned to first odor inhalation
Raster and firing-rate traces for neuron 52 across four odor and context conditions, aligned at first odor inhalation.

Each tick is a spike; the dashed line marks first odor inhalation. The lower panels average firing rate for each odor–context combination. OR/OU identify the odor and CR/CU identify the visual context.

A causal point-process model

Spikes were binned in 50 ms windows and modeled as Poisson counts. Each task event enters as a one-bin impulse followed by a causal 1.25 s response kernel. The exploratory design also included separate kernels for context exit. For the presentation below, I show and ablate the four identity-specific blocks that matter for the main result: OR, OU, CR and CU. Context-exit blocks were evaluated but are omitted from the figure and table because they do not contribute materially to the result discussed.

log μi,t = β0 + fevents(t) + hi(yi,t−1:t−30) [+ hj(yj,t−1:t−30)]μ is the expected spike count in a 50 ms bin. History is causal and spans the preceding 1.5 s; the bracketed term is used only for the 52 → 45 comparison.

Regularization strength is selected inside each training split, and all model scores are evaluated on complete held-out trials. The score is held-out Poisson log likelihood expressed as bits per spike relative to a constant-rate baseline: higher is better.

Neuron 52 carries identity-specific event information

Across all four odor–context combinations, replacing shared event kernels with identity-specific kernels improves the event-only prediction of neuron 52. The scores below come from the full exploratory identity model; the displayed figure and ablation table focus on the four odor and context-entry blocks described above.

Identity-specific events
+0.055
bits / spike over shared event kernels
Positive in 20/20 splits
5th–95th: +0.027 to +0.080
After adding self-history
+0.008
bits / spike over shared event kernels
Positive in 17/20 splits
5th–95th: −0.004 to +0.019
Neuron 52, all four odor–context combinations; mean held-out score over 20 trial splits.
ModelShared event kernelsIdentity-specific kernelsChange
Task events only0.2720.327+0.055
Task events + neuron 52 history0.6030.611+0.008

The difference becomes smaller once the model receives the neuron's own recent history. This is not temporal leakage: the history is strictly causal and is evaluated on held-out trials. Recent activity from a neuron selective for OR already acts as a proxy for the stimulus that activated it; once the model sees recent spikes from neuron 52, some of the information previously supplied by event identity is already represented in the neuron's own history.

Identity-specific event filters for neuron 52
Four causal GLM filters showing the event-specific weights for neuron 52: rewarded and unrewarded odors and rewarded and unrewarded context entry.

These are the four displayed regularized coefficients from the full exploratory fit on all four trial types; they describe the model after the held-out comparison, rather than serving as an additional test. Odor kernels are aligned to first inhalation; context-entry kernels to context entry.

Which of the four main event blocks matter for predicting neuron 52? Each row removes one identity block from the event-only model.
Removed event blockHeld-out loss5th–95th rangePositive splitsFilter L2 norm
OR0.071+0.048 to +0.10320 / 205.073
OU0.017−0.008 to +0.03218 / 202.869
CR0.005−0.008 to +0.01315 / 202.317
CU−0.003−0.009 to +0.0024 / 201.294

Held-out loss is the full event model minus the ablated model, in bits per spike. The L2 norm summarizes coefficient magnitude in the descriptive full-data fit; it is not itself a significance test.

What this supports

Within this recording and these held-out trial resamples, neuron 52 has a robust event-related component whose shape depends on odor/context identity. This is evidence about predictive task structure, not a claim about a circuit mechanism.

The 5th–95th range summarizes the 20 overlapping resamples of this recording; it is not a between-animal or between-session confidence interval.

What does the coupling model show?

The coupling result follows the same stimulus selectivity. Adding neuron 52’s recent spikes improves prediction of neuron 45 in both OR conditions, where 52 is strongly activated, but not in the two OU conditions. This is the pattern expected if 52 carries conditionally inhibitory information about 45 when the rewarded odor is present.

OR + CR: adding 52 history
+0.014
bits / spike over events + 45 history
Positive in 19/20 splits
5th–95th: +0.0004 to +0.0357
OR + CU: adding 52 history
+0.035
bits / spike over events + 45 history
Positive in 19/20 splits
5th–95th: +0.0035 to +0.0687
Neuron 45 by condition: does neuron 52 add held-out predictive information?
ConditionEvents + 45 history+ 52 historyChange5th–95th rangePositive splits
OR + CR0.1600.175+0.014+0.0004 to +0.035719 / 20
OR + CU0.0600.095+0.035+0.0035 to +0.068719 / 20
OU + CR0.0620.061−0.001−0.0226 to +0.024310 / 20
OU + CU0.0310.030−0.001−0.0080 to +0.003511 / 20
Condition-specific history filters from neuron 52 when predicting neuron 45
Four causal GLM filters showing how spikes in neuron 52 affect prediction of neuron 45 across the four odor and context conditions.

In both OR conditions, the regularized coupling filters are predominantly negative: conditional on task events and neuron 45 history, a recent spike in 52 tends to lower the model’s expected spike count for 45. The filters are descriptive fits; the table above is the held-out test.

Does this support a 52 → 45 inhibitory link?

The coupling model is consistent with the inhibitory hypothesis: adding neuron 52’s recent spikes improves held-out prediction of neuron 45 in both OR conditions, and the fitted OR coupling filters are predominantly negative. That pattern is suggestive, but it is not yet a causal test.

The timing check asks whether the two neurons occupy the right temporal order for a causal interpretation. Rates are measured in three fixed windows aligned to first odor inhalation: a pre-odor baseline from −2.0 to −1.5 s, a pre-event window from −0.5 to 0 s, and a post-event window from 0 to +1.0 s. The baseline uses all 151 trials with an observed odor inhalation; no trial had to be discarded because its odor event occurred too early for the baseline window.

How the three analysis windows are defined
Average firing rates for neurons 45 and 52 in OR plus CR trials aligned to first odor inhalation, with shaded baseline, pre-odor and post-odor windows.

The PSTH shows neurons 45 and 52 in OR + CR, the condition that most strongly suggests an anticipatory effect by eye. The shaded regions are the exact intervals used in the tests below.

Neuron 45 baseline
10.13
Hz · −2.0 to −1.5 s
Neuron 52 baseline
7.99
Hz · −2.0 to −1.5 s
Mean rates and one-sample tests against the all-trial baseline. Intervals are 95% confidence intervals for the difference from baseline. The adjusted p column applies Bonferroni correction across the four neuron-52 comparisons.
NeuronConditionWindowMean rateΔ vs baseline95% CI for Δpp adjusted
45OR + CRPre8.03 Hz−2.10[−3.48, −0.72]0.0035—
45OR + CUPre11.48 Hz+1.35[−0.12, +2.82]0.070—
45OR + CRPost3.63 Hz−6.50[−7.36, −5.63]2.8×10−22—
45OR + CUPost4.90 Hz−5.23[−6.17, −4.29]2.1×10−12—
52OR + CRPre8.70 Hz+0.71[−1.19, +2.62]0.4581.000
52OR + CUPre8.06 Hz+0.08[−1.56, +1.71]0.9231.000
52OR + CRPost51.90 Hz+43.92[+40.40, +47.43]4.6×10−341.8×10−33
52OR + CUPost49.81 Hz+41.82[+34.96, +48.68]2.2×10−138.7×10−13
What the analysis supports

The timing check shows neuron 45 below baseline before the odor in OR + CR, and the suppression becomes even stronger afterward. Neuron 52 does not differ from baseline before the odor in either OR condition, but rises sharply afterward. The model is therefore compatible with a condition-dependent inhibitory functional association. However, the temporal analysis undermines a simple causal interpretation: neuron 45 already changes before neuron 52 shows its strongest event-locked response, and both signals are structured by the same task events.