Fig. 6: Visual discrimination impacted the stability but not the accuracy of stimulus representation.

a Schematic of visual discrimination task. b Six of six mice (m) learned the visual discrimination task. All mice achieved a behavioral d-prime above 1.5 within 10 days. c Tuning stability of all tracked, visual responsive and tuned neurons (n = 320 neurons), pooled across the 5 of 6 mice. Neurons were required to be tuned on both imaging sessions (baseline and 30-days training) to be included. d Distribution of orientation preference for all visually responsive neurons in two cohorts of mice. Six naive mice were imaged 15 days apart. The distributions were not different (Chi-square test, p = 0.863; n = 1178 and 689 neurons). The six mice in ‘b’ were imaged before, during, and after training. The distributions after 15 and 30 days of training were significantly different from baseline (Chi-square test, p < 0.001 both conditions; baseline, 15-days, 30 days: n = 1311, 804, and 762 neurons). Data were pooled across animals. e Decoding accuracy of orientation (spatial frequency of 0.04 cycles/°) was similar before and after training (Wilcoxon signed-rank test, p = 0.999, n = 6 animals). The number of neurons used to classify orientation was matched across conditions for each animal: 167,144,122,150,101,110. Chance probability was 0.083 (dashed line). f Example confusion matrices before and after visual discrimination training, mouse #1. g Cross-session classification of orientation at a spatial frequency of 0.04 cycles/° after visual discrimination training was significantly lower compared to baseline (paired t-test, p = 1.6E−3, n = 5 animals). All tracked neurons were included, including those not visually responsive (number of neurons for each mouse, respectively: 272, 292, 329, 264, 248). Mouse IDs as in ‘e’. Mouse #2 was not included due to a neuron tracking error. Chance probability was 0.083 (dashed line). **p < 0.001. h The difference in cross-session decoding accuracy of orientation at a spatial frequency of 0.04 cycles/° was significantly lower (t-test, p = 0.035, n = 5 animals in each condition) after visual discrimination training (data from ‘g’) compared to control animals (number of neurons for control mice: 133, 64, 49, 191, 232). *p < 0.05. Source data are provided as a Source Data file.