CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells...

56
1 CA1 pyramidal cells organize an episode by segmented and ordered events 1 Chen Sun 1, * , Wannan Yang 3 , Jared Martin 1 , & Susumu Tonegawa 1, 2, * 2 1 RIKEN-MIT Laboratory for Neural Circuit Genetics at the Picower Institute for Learning and Memory, Department 3 of Biology and Department of Brain and Cognitive Sciences, Massachusetts Institute of Technology, Cambridge, 4 Massachusetts 02139, USA 5 2 Howard Hughes Medical Institute at Massachusetts Institute of Technology, Cambridge, MA 02139, U.S.A. 6 3 School of Biological Sciences, The University of Edinburgh, Edinburgh EH8 9YL, UK 7 *To whom correspondence should be addressed: C.S. ([email protected]) or S.T. ([email protected]) 8 9 ABSTRACT 10 11 A prevailing view is that the brain represents episodic experience as the continuous moment to 12 moment changes in the experience. Whether the brain also represents the same experience as a 13 sequence of discretely segmented events, is unknown. Here, we report a hippocampal CA1 14 “chunking code”, tracking an episode as its discrete event subdivisions (“chunks”) and the 15 sequential relationships between them. The chunking code is unaffected by unpredicted 16 variations within the events, reflecting the code’s flexible nature by being organized around 17 events as abstract units. The chunking code changes accordingly when relationships between 18 events are disrupted or modified. The discrete chunking code and continuous spatial code are 19 represented in the same cells, but in an orthogonal manner, and can be independently perturbed. 20 Optogenetic inactivation of MEC inputs to CA1 disrupts the chunking but not spatial code. The 21 chunking code may be fundamental for representing an episode, alongside codes tracking 22 continuous changes. 23 24 . CC-BY-NC-ND 4.0 International license certified by peer review) is the author/funder. It is made available under a The copyright holder for this preprint (which was not this version posted March 5, 2019. . https://doi.org/10.1101/565689 doi: bioRxiv preprint

Transcript of CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells...

Page 1: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

1

CA1 pyramidal cells organize an episode by segmented and ordered events 1

Chen Sun1, *, Wannan Yang3, Jared Martin1, & Susumu Tonegawa1, 2, * 2

1RIKEN-MIT Laboratory for Neural Circuit Genetics at the Picower Institute for Learning and Memory, Department 3

of Biology and Department of Brain and Cognitive Sciences, Massachusetts Institute of Technology, Cambridge, 4

Massachusetts 02139, USA 5

2Howard Hughes Medical Institute at Massachusetts Institute of Technology, Cambridge, MA 02139, U.S.A. 6

3School of Biological Sciences, The University of Edinburgh, Edinburgh EH8 9YL, UK 7

*To whom correspondence should be addressed: C.S. ([email protected]) or S.T. ([email protected]) 8

9

ABSTRACT 10

11

A prevailing view is that the brain represents episodic experience as the continuous moment to 12

moment changes in the experience. Whether the brain also represents the same experience as a 13

sequence of discretely segmented events, is unknown. Here, we report a hippocampal CA1 14

“chunking code”, tracking an episode as its discrete event subdivisions (“chunks”) and the 15

sequential relationships between them. The chunking code is unaffected by unpredicted 16

variations within the events, reflecting the code’s flexible nature by being organized around 17

events as abstract units. The chunking code changes accordingly when relationships between 18

events are disrupted or modified. The discrete chunking code and continuous spatial code are 19

represented in the same cells, but in an orthogonal manner, and can be independently perturbed. 20

Optogenetic inactivation of MEC inputs to CA1 disrupts the chunking but not spatial code. The 21

chunking code may be fundamental for representing an episode, alongside codes tracking 22

continuous changes. 23

24

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 2: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

2

Main text 25

26

How is an episode represented in the brain? It has long been thought that the hippocampus (1) 27

encodes the space, objects, and time (2-4) in daily episodes. Early studies revealed hippocampal 28

cells that code for variations in space (5). Subsequently, hippocampal CA1 cells have been found 29

to be tuned to variations of non-spatial modalities such as passing time (6, 7) and variations in 30

sensory stimuli (6-11). As a result, a unified view of the hippocampus has emerged as a sequence 31

generator that encodes an episode by tracking its moment-to-moment continuous variations in 32

variables such as space, passing time, and sensory stimuli. 33

34

In parallel, psychologists and others, have theorized that episodes are fundamentally subdivided 35

by the brain into events or chunks (2, 4, 8-11). Indeed, in real life, rather than remembering all 36

the moment-to-moment continuous variations in their spatio-temporal domain, a typical episode, 37

for instance attending a dinner party, is remembered in terms of segmented events: being led to 38

their designated table, ordering from the menu, waiting for the food, enjoying the jazz band, 39

doing this, and then doing that, etc. An every-day analogy to understand the importance of 40

chunking is to consider the use of folders to organize all the raw documents and data that resides 41

in the computer. Without the widespread use of folders to subdivide computer data into chunks, 42

the organization of data would be an unworkable mess. In other neural systems, visual scenes are 43

segmented by the brain at the highest processing level into discrete objects (12, 13), and motor 44

sequences produced by the brain rely on discrete motor sub-programs (14, 15). These examples 45

reflect discretization as a general organizational principle of both the computer, and perhaps the 46

brain. 47

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 3: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

3

48

Whether episodic experience, too, is fundamentally segmented by the brain into chunks is not 49

known. The present study aims to investigate whether the hippocampal CA1 subfield carries a 50

code organized around events as fundamental units of episodic experience, supported by the 51

sequentially ordered relationships between these events. Although episodic experience is 52

behaviorally continuous, a chunking process in the brain should allow it to flexibly and 53

efficiently code wide variations in the episodic experiences by organizing around meaningful 54

events, above every moment’s detail. Such an event tracking code could be one of the 55

fundamental organizing principles of episodic experience by the brain. 56

57

Task design to study segmentation of episodic experience into events and relations between 58

them: revealing the “chunking code” 59

60

An ordinary episodic experience contains spatial and object variations (Fig. 1a top, middle). We 61

designed our behavior task to be a ‘skeletal’ version of ordinary episodic experience: a sequence 62

of events stripped of differences in spatial and sensory variations to minimize their influence on 63

episodic representations (Fig. 1a, bottom). In our task episode, mice repeatedly ran through a 64

square maze with four laps per trial (Fig. 1d) driven by delivery of a reward at the onset of lap 1 65

only. These mice visited the reward box after every lap regardless whether a reward was delivered 66

or not (Extended Data Fig. 1a) before starting the next lap. There were two experimental purposes 67

for this task design. First, despite the task experience being continuously run, we aimed to see 68

whether a neural code could be found that organized this continuous episode (Fig. 1a top) based 69

on what may be regarded as subdivisions of the task experience: the lap events (Fig. 1a bottom). 70

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 4: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

4

By design, such a neural code would not be tracking different sensory cues since sensory 71

information was identical between the laps, unlike tasks used in other studies (5-7, 16-26) in which 72

different events reflect different, constant sensory presentations of visual cues, tones, or odors 73

(Illustration Fig. 1a middle). Rather differently, in our task design, the lap events would reflect a 74

more abstract entity, as we will show. Second, having established events as fundamental 75

organizing units of episodic experience, in our particular task the lap events would then reflect a 76

further special property within the experience. Since each of the four lap events was materially 77

identical to one another, if hippocampal CA1 neurons differentially code lap 1, lap 2, lap 3, and 78

lap 4, it would be a code that reflects the abstract sequential relationships between otherwise 79

identical events. To illustrate, representing lap n reflects the pure, iterative relationship to the 80

previous lap n-1 and the subsequent lap n+1. Such a representation of abstract sequential 81

relationships would reveal an organizational scheme of episodic experience based on these events. 82

83

A virus expressing the calcium indicator GCaMP6f (AAV2/5-Syn-DIO-GCaMP6f) (27) was 84

injected into dorsal CA1 (dCA1) of the hippocampus in Wfs1 (Wolframin-1) promoter-driven Cre 85

transgenic mice (Fig. 1b) (28, 29). A microendoscope was implanted above dCA1 (30) to enable 86

long-term calcium imaging in freely moving mice (Fig. 1b, c). We recorded calcium activity and 87

characterized the spatial selectivity of CA1 neurons (Extended Data Fig. 1c) as mice ran the square 88

maze task (Fig. 1d). During testing, animals completed 15-20 trials in succession. On average, test 89

mice took 98 seconds to complete one trial (Fig 1e). For each neuron during each of the four laps, 90

we calculated its average calcium activity strength during moving periods (> 4 cm/s) to identify 91

differences in calcium dynamics that were related to the lap number (Fig. 1g). Some neurons were 92

found to be most active during reward consumption (lap 1) in the reward box (Extended Data Fig. 93

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 5: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

5

1d: representative neurons); these cells were excluded from further analysis because they were 94

active in direct response to the reward (Methods). In general, neurons that were active in the start 95

box during non-rewarded laps, or in the maze, were active at the same location on every lap 96

(Extended Data Fig. 1b, e), but showed a preference for a specific lap (Fig. 1g) with stronger 97

activity than in other laps. We calculated and plotted the trial-by-trial calcium activities of 98

representative neurons for each of the four laps. Representative neurons preferred a particular lap, 99

reliably across individual trials (Fig. 1g, Extended Data Fig. 2). Two representative cells that were 100

observed together in the same animal during the same experiment were active in the same spatial 101

location on the track, but were preferentially and consistently active on different laps (Fig. 1g: lap 102

1 vs lap 2 cell from animal 197; Extended Data Fig. 2: lap 2 vs lap 4 cell from animal 285). 103

104

We calculated the calcium activity across the four laps within spatial bins that tiled the maze 105

(Methods). Since CA1 activity is sensitive to a variety of behavioral variables including spatial 106

location (5), running speed (31, 32), and head direction (32, 33) (Extended Data Fig. 3a-b), we 107

fitted the activity of each neuron to a linear model incorporating the animal’s spatial location, head 108

direction, and running speed (Methods) to account for these variables. We then asked whether 109

these modelled variables were enough to account for the systematic variation in CA1 activity. Thus, 110

we calculated the remaining calcium activity across four laps that was not accounted for by the 111

model and referred to this activity to as ‘model corrected’, or MC, calcium activity (Fig. 1h). Thirty 112

percent (1055/3506 cells, n = 14 mice) of CA1 pyramidal cells had peak, lap-specific MC activity 113

that was significantly different (outside the 95th confidence interval) compared to shuffles. These 114

cells are henceforth called ‘chunking cells’ because their activity is modulated by the lap events 115

(i.e. the chunks) that make up the episode. 116

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 6: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

6

117

There were chunking cells that preferred each of the four laps (Fig. 1i). In order to examine the 118

pattern of calcium activity modulated by lap for a given cell, we calculated its lap modulated MC 119

activity in the peak spatial bin (Fig. 1h, bottom; Methods) for all four laps; we call this sequence 120

of differential activity strengths across the four laps the ‘chunking code’ (Fig. 1h, bottom). The 121

percentage of chunking cells increased from 17% on the first day to 29% following eight days 122

training on the lap task (see Methods; pre: 176/1008 cells in n=5 mice; post: 335/1168 cells in the 123

same mice; Extended Data Fig. 4; χ2 =37.9, p = 7.4*10-10) showing that the chunking code is 124

learned. We tracked chunking cells across days and saw that their chunking codes were highly 125

correlated even across days (Fig. 1l, Examples: Fig. 1j-k;—Extended Data Fig. 5a for the 126

analogous raw ΔF/F results). 127

128

The chunking code is unaffected by variations within events 129

130

Despite the fact that animal behavior was continuous throughout the task and without experimental 131

breaks, several key results indicated that the chunking code was organized around discrete 132

subdivisions of the episodic experience (i.e. laps). First, although chunking cells were periodically 133

active on each of the 4 laps (Fig. 1f, Extended Data Fig. 1b) the vast majority of them had 134

statistically significant enhanced activity, according to the above criterion, on only one of those 135

laps (Fig. 2a left), indicating relatively sharp lap-specific tuning. 136

137

Second, since previous studies (5-7, 17, 34) showed hippocampus codes for continuously changing 138

variables, we investigated the chunking code compared to several continuous variable codes more 139

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 7: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

7

closely. Could chunking cells instead be tracking a particular duration of time since the start of the 140

trial? In fact, episodic or time cells (6, 7) require a constant and reliable temporal delay period; 141

otherwise they do not arise (7). Because the animals in our task were freely behaving and exhibited 142

unpredictable and variable durations to complete the trials of the task (Fig. 2b), they were unlikely 143

to be time cells. Could chunking cells instead be representing the total distance continually 144

travelled along the course of the 4-lap task since the start of the trial? To test this, we conducted a 145

consecutive two-day experiment in which we elongated the maze in one dimension to twice the 146

usual length on the 2nd day while the animals continued to undergo the standard 4-lap-per-trial task 147

(Fig. 2c, Methods: task specific training). The chunking code was significantly preserved across 148

days (Fig. 2d, Examples: Fig. 2e-f; raw ΔF/F: Extended Data Fig. 5b) despite the spatial distortions 149

of maze length, making it unlikely that chunking cells track the continuous distance traveled. 150

151

Finally, real episodic experience has a high degree of variability. To investigate this point further, 152

we next performed a single day experiment with the 4-lap-per-trial task in which the maze was 153

elongated on pseudo-randomly chosen laps of pseudo-randomly chosen trials (Fig. 2g left, 154

Extended Data Fig. 6 for full task schedule, Methods). This maze was largely stripped of 155

predictability in travelled distance but preserved only the 4-discrete lap structure. A total of 26% 156

of CA1 cells (331/1257 cells, n = 6 animals) active in all trial types of this experiment were 157

significant chunking cells. For these chunking cells, their sequence of lap-to-lap pattern of activity 158

strengths (i.e. their chunking code) during the standard (short SSSS) trials was still preserved 159

during each of the pseudo-randomly elongated trial types (Fig. 2i-k; Example cell: Fig. 2h, raw 160

ΔF/F: Extended Data Fig. 5d). For these cells, their chunking codes were even preserved during 161

SSLL trials compared to LLSS trials (Fig. 2l), which were trials that had the same total distance 162

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 8: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

8

(Fig. 2g right) but differed in their internal segmentation into four lap events. Therefore, the 163

chunking code of this sizeable population of CA1 cells was unperturbed by arbitrary and 164

unpredicted variations within the relevant lap or even variations within neighboring (preceding 165

and ensuing) laps (Fig. 2g right for illustration). These results further indicate that the chunking 166

code treats these lap events as organizing units of the experience. 167

168

It can be seen that the chunking code tracks these lap events in an abstract manner, robust against 169

arbitrary variabilities in physical variables like time (Fig. 2b) or distance (Fig. 2g). We conducted 170

one final examination of the abstract nature of these events. A two day experiment was conducted 171

in which the 4-lap per reward was still preserved on the 2nd day (Extended Data Fig. 7, raw ΔF/F: 172

Extended Data Fig. 5e), whereas the spatial trajectories were altered every two laps (Extended 173

Data Fig. 7, Methods: task specific training) to perturb spatial sequences during the same lap 174

events. Here, a significant proportion of lap 1-4 chunking cells still had preserved chunking code 175

across sessions (Extended Data Fig. 7) despite the animal experiencing differential spatial 176

trajectories. This shows the abstract nature of these “lap events”, tracked by the chunking code. 177

178

The chunking code tracks the sequential relationships between events 179

180

Based around these lap events, how is episodic experience then organized? The reliable 181

preservation of lap event-specific activity across trials (Fig. 1g) and across days (Fig. 1l, Examples: 182

Fig. 1j-k) suggests that the chunking code captures sequential relationships between the materially 183

identical lap events. To further test this hypothesis, we conducted two types of experiments. 184

185

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 9: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

9

First, we conducted an experiment in which reward was provided every lap, in order to abolish the 186

sequentially differentiating effect of the once-in-four lap delivery of the reward (Fig. 3a, left). We 187

found that only 9% (101/1072 cells, n= 5 animals, Fig. 3a right, and Fig. 3b) of CA1 cells were 188

significant chunking cells. This was significantly lower than the percentage of chunking cells 189

observed in the standard 4-lap-per-trial experiments in those same animals (28% = 371/1328 cells 190

in the same animals, χ2 =128.7, p = 0.0). 191

192

Second, we conducted a consecutive two-day experiment with the standard 4-lap-per-trial 193

experiment on the first day and added a non-rewarded 5th lap on all the trials of the second day 194

before reward eating (Fig. 3c, Methods: task specific training). We postulated that this subtle 195

modification of the ordering of events may be sufficient to perturb the chunking code. During day 196

2 of testing, while lap 1 and 2 cells had preserved chunking code despite the additional lap (Fig. 197

3d; raw ΔF/F: Extended Data Fig. 5c), lap 3 cells were perturbed (Fig. 3d), and a significant 198

proportion of them (17/55 cells = 31%, n = 4 mice, p < 10-3 compared to shuffling) shifted to prefer 199

lap 4 (Fig. 3e-f). This was despite the fact that lap 3 and the preceding (lap 2) and succeeding laps 200

(lap 4) were materially identical to each other, as well as across days. Lap 4 cells showed a 201

similarly shifted chunking code to prefer lap 5 (Fig. 3g-h). Although, overall, the pattern of a 202

majority of Lap 4 cell activity across the two days was well correlated across the first 4 laps (Fig. 203

3d), a proportion of lap 4 cells (42/60 cells = 70%, n = 4 mice, p < 10-4 compared to shuffling) 204

were subtly perturbed. These data show a decrease in overall activity strength during lap 4 on day 205

2 (Fig. 3i) with a concomitant restoration of activity strength during lap 5 (Fig. 3j). Thus, the 206

alterations of the materially identical lap 3 and 4 representations were due to the addition of the 5th 207

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 10: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

10

lap that changed the sequential structure of the task. Such alterations perturbed lap 3 and 4’s 208

prospective sequential relationships to the end of the trial. 209

210

Interestingly, when the sequential organization of events was altered by the addition of this extra 211

lap, the chunking code was correspondingly altered as well, but it did so in a discrete, lap-specific 212

manner rather than gradually through the course of the task experience (Fig 3d). Indeed, whereas 213

lap 1 and 2 representations were well correlated across days, representations during lap 3 were 214

abruptly and discretely altered. This further supports the idea that the chunking code organizes 215

episodic experience around discrete segments—and even chunking code changes happen to occur 216

along these natural segments of the episode. 217

218

Taken together, these data show that the chunking code organizes an episode around events and 219

reflects the abstract sequential relationships between them. 220

221

Chunking and spatial codes are jointly but independently represented in the same cells 222

223

What is the relationship between the chunking code for discrete events and the well-known place 224

code for continuously changing space (5)? The chunking and spatial codes occur in the same cells, 225

yet are treated in an orthogonal manner: the spatial code manifests as where on the spatial track 226

the neuron is active, and the chunking code manifests as how much the neuron is active, during 227

each different laps (Fig. 4a), without affecting the spatial tuning during each lap (Fig. 1f, Extended 228

Data Fig. 1b). Within this joint arrangement of the two codes, we further hypothesized that the 229

discrete chunking code could be manipulated independently from the continuous spatial code. 230

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 11: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

11

When the maze and task were not altered in any way across days, both chunking and spatial 231

representations remained highly correlated (Fig. 4g). In contrast, perturbing the sequential 232

relationships between events by adding a lap (Fig. 3c) altered some chunking representations (Fig. 233

3d-f, Fig. 3k, orange histogram) but still preserved spatial representations in the same cells (Fig. 234

3k, blue histogram). 235

236

A perturbation of the chunking code can also be seen in a different experiment. Since medial 237

entorhinal cortex (MEC) input into CA1 has been implicated in the sequential organization of 238

episodes (35-38), we asked how MEC inhibition might affect the chunking code versus the spatial 239

code. Based on these earlier studies, a virus expressing inhibitory opsin (AAV2/2-EF1a-DIO-240

eNpHR3.0-mCherry) was injected bilaterally into the MEC sub-region of pOxr1-Cre mice (Fig. 3l 241

left, 3m). In addition, a virus expressing the calcium indicator GCaMP6f (AAV2/5-CamKII-242

GCaMP6f- WPRE-SV40) was unilaterally injected into dorsal CA1 (dCA1) of the same mice (Fig. 243

3l left). An opto-endoscope was implanted above dCA1 to enable long-term calcium imaging as 244

well as optogenetic inhibition of the axonal terminals from MEC neurons in dCA1. The mice ran 245

28-40 trials of the 4-lap task where the trials alternated between inactivation (Light-On) and no 246

inactivation (Light-Off) (Fig. 3l). Inactivation of MEC cell terminals in dCA1 globally altered 247

chunking representations but did not change the spatial representations in the same cells (Fig. 3o-248

p, Example cells: Fig. 3n, Extended Data Fig. 8). Therefore, the chunking code is different from 249

the spatial code even though they are represented jointly in the same cells. 250

251

Can the converse result, spatial code alteration without chunking code alteration, be observed? To 252

investigate this point, we conducted a consecutive two-day experiment in which we rotated the 253

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 12: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

12

maze by 90 degrees on the 2nd day while the animals continued to undergo the standard 4-lap-per-254

trial task (Fig. 4b, Methods: task specific training). In this case, the chunking code for lap 1, 2, 3 255

and 4 cells were all preserved across days (Fig. 4c, Fig. 4f, orange histogram; raw ΔF/F: Extended 256

Data Fig. 5f) despite the spatial rotation of the entire maze. The chunking code preservation was 257

in contrast to a change in spatial field location, relative to the maze, in the same cells (Fig. 4f, blue 258

histogram, Examples: Fig. 4d-e). In this way, the same cell can simultaneously code a different 259

spatial moment within the lap run, and still code the same lap event number. 260

261

Thus, these experiments show that the hippocampal CA1 chunking code, manifested as event-262

modulated activity strengths, is jointly yet orthogonally represented in the same cells as the spatial 263

code, and the two codes can be manipulated independently of one another. 264

265

The discrete chunking code is also jointly represented with the continuous time code 266

267

If indeed the brain tracks episodic experience jointly via a discrete chunking code and a continuous 268

spatial code, would it continue to represent episodes in this dual manner even in an episode where 269

the main continuous changes are not spatial? To answer this question, we conducted another 4-270

lap-per-trial experiment using a continuous time code. In this experiment, the first arm of the 271

standard 4-lap-per-trial maze was replaced by a treadmill (Fig. 5a). Animals ran for 12s on a 272

treadmill at 14 cm/s on every lap. Monitoring activity of neurons on a treadmill obviates the 273

necessity of model corrections for running speed and head direction changes (Fig. 1h) because 274

they are nearly constant on the treadmill (Extended Data Fig. 9a-b). The treadmill experiences 275

gave rise to time-modulated cells (6, 7) (Fig. 5d) that tiled the 12s experience (Fig. 5b, Extended 276

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 13: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

13

Data Fig. 9c), just as place cells had previously tiled the length of the maze run (Fig 1f). On the 277

treadmill, 20% of CA1 cells (243/1222 cells, n = 5 animals) had significantly different activity 278

depending on the lap number (i.e. the chunking code) (Fig. 5e, Methods, and examples: Fig. 5c, 279

Extended Data Fig. 9d). It can be checked that the chunking code of these cells during the treadmill 280

period was robustly preserved between trials (Fig. 5f). Note that the percentage of chunking cells 281

was significantly reduced during the control task where reward was given every lap (6% = 42/681 282

cells, n = 3 animals, Fig. 5g-i). These results show that the simultaneous tracking of episodes in 283

both a discrete manner and a continuous manner is a fundamental organizing principle, regardless 284

whether the episodic experience is primarily spatial or temporal in nature (Fig. 6). 285

286

DISCUSSION 287

288

How does the hippocampus encode an episodic experience? The main finding of this study was 289

the identification of a hippocampal code that organizes around discrete subdivisions of the episode 290

(i.e. events) and their sequential relationships to one another—the chunking code. While there has 291

emerged a view that the hippocampus tracks an episode as a sequence generator (5-7, 16-25, 39, 292

40) by tracking the moment to moment continuous variations for both spatial or non-spatial 293

moments, in this study the chunking code tracks the same episodic experience within the same 294

CA1 cells via a different organizing principle: organizing it around discrete chunks of experience 295

and their relationships (Fig. 2). In our task (Fig. 1d) the chunking of experience into events did not 296

require any differential sensory cues (5-7, 16-25, 39) to define an event or permit the distinction 297

of these events from one another, nor even require any differential past or future sensory cues (19, 298

25). Instead, these events had an abstract nature, unchanged by variations in distance travelled 299

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 14: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

14

(Fig. 2c-f), time duration (Fig. 2b), changes in spatial trajectories (Extended Data Fig. 7), or even 300

spatial rotation of the entire episode (Fig. 4). Even when the chunking code changed (Fig. 3d), it 301

changed along the segments of the episode—in a discrete, lap-specific manner—rather than 302

gradually through the course of the task experience, showing that a lap event is treated as a discrete, 303

unitary entity by the chunking code. 304

305

In the end, organizing an episode based on the discrete chunking code tracking events and their 306

relationships, and a continuous code tracking moment to moment changes during the same episode, 307

coexist in the hippocampus. In fact, the discrete chunking code and continuous code are jointly 308

represented in the same cells for both spatial and non-spatial episodes (Fig. 4-5). This supports the 309

concept that the simultaneous tracking of episodes in both a segmented and continuous manner is 310

a fundamental and general encoding principle, which the hippocampus uses. Nevertheless, the two 311

codes are separate representations: in fact, the chunking code and spatial code can be 312

independently altered without affecting the other (Fig. 3k, 3p, Fig. 4f, 4g). In fact, the two joint 313

codes represent different aspects of the same episodic experience. Indeed, the tracking of 314

immediate experience within an event likely requires a level of detail that would be best served by 315

a continuous (spatial or non-spatial) neural representation. On the other hand, tracking the 316

meaningful episodic events above the moment-to-moment variational details is best served by a 317

flexible and discrete representation (Fig. 6). This study provides experimental evidence for a novel 318

“chunking code” in the hippocampus tracking events and their relationships, which could be a 319

fundamental code by which episodic experience is encoded efficiently and flexibly in the brain. 320

321

Acknowledgements 322

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 15: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

15

We thank T. Kitamura, J. Z. Young, D. Roy, M. Wilson, E. Brown, M. Sur, M. Harnett, M. 323

Hasselmo, S. Muralidhar, B. Sun, J. Tao, N. Chen and C. MacDonald for comments; F. Bushard, 324

A. Hamalian, C. Ragion, C. Lovett, D. King, and Ella Maru Studio for technical assistance; L. 325

Brenner for paper preparation, and the members of Tonegawa lab for their support. This work 326

was supported by the RIKEN Center for Brain Science, the Howard Hughes Medical Institute, 327

and the JPB Foundation (to ST). 328

329

Author Contributions 330

C.S., and S.T. designed the study. C.S., W.Y., and S.T. interpreted the data. C.S. and J.M. 331

conducted the surgeries, behavior experiments, and computational analyses. C.S., W.Y., and S.T. 332

wrote the paper. All authors discussed and commented on the manuscript. 333

Data availability 334

The data and code that support the findings of this study are available from the corresponding 335

authors upon reasonable request. 336

337

338

REFERENCES AND NOTES 339

1. W. B. Scoville, B. Milner, J Neurol Neurosur Ps 20, 11 (1957). 340 2. I. Kant, (Encyclopedia Britannica, Chicago, 1955). 341 3. J. N. O'Keefe, L., (Clarendon Press, Oxford, 1978). 342 4. E. Tulving, (Academic Press, New York, 1972). 343 5. J. O'Keefe, J. Dostrovsky, Brain research 34, 171 (Nov, 1971). 344 6. C. J. MacDonald, K. Q. Lepage, U. T. Eden, H. Eichenbaum, Neuron 71, 737 (Aug 25, 2011). 345 7. E. Pastalkova, V. Itskov, A. Amarasingham, G. Buzsaki, Science 321, 1322 (Sep 5, 2008). 346 8. G. Buzsaki, R. Llinas, Science 358, 482 (Oct 27, 2017). 347 9. G. Buzsaki, D. Tingley, Trends in Cognitive Sciences 22, 853 (2018). 348

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 16: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

16

10. A. Whitehead, Gifford Lectures Delivered in the University of Edinburgh During the Session 349 1927-28 (Free Press, 1979). 350

11. N. Rescher, G. Leibniz, Eds., (University of Pittsburgh Press, 1991). 351 12. J. Sergent, S. Ohta, B. MacDonald, Brain, (1992). 352 13. N. Kanwisher, J. McDermott, M. Chun, Journal of Neuroscience, 4302 (1997). 353 14. N. Fujii, A. M. Graybiel, Science 301, 1246 (2003). 354 15. H. K. Inagaki, L. Fontolan, S. Romani, K. Svoboda, Nature 566, 212 (2019). 355 16. T. A. Allen, D. M. Salz, S. McKenzie, N. J. Fortin, Journal of Neuroscience 36, 1547 (Feb 3, 2016). 356 17. D. Aronov, R. Nevers, D. W. Tank, Nature 543, 719 (Mar 29, 2017). 357 18. H. Eichenbaum, M. Kuperstein, A. Fagan, J. Nagode, Journal of Neuroscience 7, 716 (Mar, 1987). 358 19. L. M. Frank, E. N. Brown, M. Wilson, Neuron 27, 169 (Jul, 2000). 359 20. M. Fyhn, T. Hafting, A. Treves, M. B. Moser, E. I. Moser, Nature 446, 190 (Mar 8, 2007). 360 21. S. Leutgeb et al., Science 309, 619 (Jul 22, 2005). 361 22. J. R. Manns, M. W. Howard, H. Eichenbaum, Neuron 56, 530 (Nov 8, 2007). 362 23. Y. Sakurai, Neuroscience 115, 1153 (2002). 363 24. S. Terada, Y. Sakurai, H. Nakahara, S. Fujisawa, Neuron 94, 1248 (Jun 21, 2017). 364 25. E. R. Wood, P. A. Dudchenko, R. J. Robitsek, H. Eichenbaum, Neuron 27, 623 (Sep, 2000). 365 26. E. R. Wood, P. A. Dudchenko, H. Eichenbaum, Nature 397, 613 (1999). 366 27. T. W. Chen et al., Nature 499, 295 (Jul 18, 2013). 367 28. T. Kitamura et al., Science 343, 896 (Feb 21, 2014). 368 29. T. Okuyama, T. Kitamura, D. S. Roy, S. Itohara, S. Tonegawa, Science 353, 1536 (Sep 30, 2016). 369 30. Y. Ziv et al., Nat Neurosci 16, 264 (Mar, 2013). 370 31. A. Czurko, H. Hirase, J. Csicsvari, G. Buzsaki, Eur J Neurosci 11, 344 (Jan, 1999). 371 32. B. L. McNaughton, C. A. Barnes, J. O'Keefe, Exp Brain Res 52, 41 (1983). 372 33. S. Leutgeb, K. E. Ragozzino, S. J. Y. Mizumori, Neuroscience 100, 11 (2000). 373 34. P. Ravassard et al., Science 340, 1342 (2013). 374 35. A. Tsao et al., Nature 561, 57 (2018). 375 36. J. Suh, A. J. Rivest, T. Nakashiba, T. Tominaga, S. Tonegawa, Science 334, 1415 (2011). 376 37. T. T. G. Hahn, J. M. McFarland, S. Berberich, B. Sakmann, M. R. Mehta, Nat Neurosci 15, 1531 377

(2012). 378 38. J. Yamamoto, J. Suh, D. Takeuchi, S. Tonegawa, Cell 157, 845 (2014). 379 39. J. L. Gauthier, D. W. Tank. (bioRxiv, 2017). 380 40. Behrens, T. E. J. et al., Neuron 100, 490 (2018). 381 41. E. A. Mukamel, A. Nimmerjahn, M. J. Schnitzer, Neuron 63, 747 (Sep 24, 2009). 382 42. W. E. Skaggs, B. L. McNaughton, K. M. Gothard, in Advances in neural information processing 383

systems. (1993), pp. 1030-1037. 384

385

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 17: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

17

386

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 18: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

18

Figure 1: Experimental design to study segmentation of episodic experience 387

a) Illustration of episodic experience as (top): sequence of continuous, moment to moment 388

variations (middle): sequence of discretely segmented events. (bottom): Skeletal task experience 389

stripped of sensory and spatial differences, still discretely segmented. 390

b) Implantation of microendoscope into dCA1 of Wfs1-Cre mice with AAV2/5-Syn-DIO-391

GCaMP6f virus injected in dCA1. 392

c) Top: Coronal section of hippocampus showing area of cortex aspiration (white line) and Wfs1+ 393

cells labelled (green). Bottom: ΔF/F calcium traces of Wfs1+ (pyramidal) cells in CA1, where 394

(red) denotes significant calcium transients identified. 395

d) During the standard 4-lap-per-trial experiment reward was delivered to the animal at the 396

beginning of lap 1 in the reward box, once every 4 such laps. 397

e) Mean run time among trials (n = 14 animals); 398

f) CA1 calcium activity sorted by spatial position and lap number, normalized and Gaussian 399

smoothed (σ = 25cm) (263 cells from example animal). Red label indicates reward box spatial bin, 400

and green label indicates the 100 cm long maze track. Reward box activity during lap 1 (reward 401

eating period) was excluded. 402

g) Trial-by-trial calcium activity of representative neurons preferring lap 1, 2, 3, and 4, with 403

spatially binned calcium activity along the track (reward box, plus 16 spatial bins along 100cm 404

track). Left panel: trial-by-trial calcium activity; Right panel: trial averaged calcium activity 405

(mean ±SD). Standard deviation was cut off at 0 because negative activity does not exist). 406

h) Left: representative neuron with raw calcium activity strength sorted by lap number (Light 407

blue), and plotted with calcium rate explained by the speed and head orientation fitted linear model 408

(Grey trace, See Methods). Right: Lap specific remaining calcium rate after the linear model was 409

subtracted, resulting in ‘model corrected’, or MC, calcium activity. Orange: peak spatial bin to 410

examine lap modulation of calcium activity 411

i) Summary statistics: Percentage of chunking cells in the whole CA1 pyramidal population that 412

were tuned to lap 1, 2, 3, or 4, in the standard 4-lap experiment (n = 14 animals). 413

j – k) Representative lap 1, 2, 3, and 4 neurons matched across 2 consecutive test days showing 414

spatial code (j) and chunking code (k), as measured by MC calcium activity. For each example 415

cell, Pearson correlations between its chunking codes across days were computed (k, bottom). 416

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 19: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

19

l) Summary data: the chunking code for individual chunking cells, Pearson correlated across days, 417

plotted separately for lap 1, 2, 3 and 4 cell populations. (Orange): Chunking activity of each cell 418

on day 1 correlated with its own chunking activity on day 2. (Grey): Chunking activity of each 419

cell on day 1 correlated with chunking activity of arbitrary cells (i.e. shuffled cell identities) from 420

day 2. The proportion of cells with highly correlated (i.e. highly preserved) chunking code across 421

days (cells with Pearson’s r > 0.6 threshold: i.e. within the Blue box) was significantly greater 422

compared to shuffles: χ2 and p values shown in the figure (622 cells, n = 8 animals). See Methods 423

for detailed calculations. 424

425

426

427

428

429

430

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 20: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

20

431

432

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 21: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

21

Figure 2: The chunking code is unaffected by variations within events 433

a) Most chunking cells had statistically enhanced activity on only one lap. 434

b) Left: Distribution of running time across trials of animal 197 during 18 trials; 435

Right: Coefficient of variation (σµ) for run time among trials, (n = 14 animals). 436

c) Fixed maze elongation experiment: 4-lap-per-trial task on: Day 1: the standard maze and Day 437

2: the elongated maze. 438

d) Chunking code correlations across standard and elongated maze sessions (448 cells, n = 6 mice). 439

See Fig. 1(l) for description and methods. 440

e– f) Representative lap 1, 2, 3, and 4 neurons matched across standard and elongated sessions. 441

g) Left: Task schedule design for the random maze elongation experiment, where laps were 442

randomly elongated every 2 laps. Right: Illustration of the random maze elongation experiment 443

with consistent 4-laps per reward despite variability within the lap events. S denotes a “short” lap. 444

L denotes a “long” lap. 445

h) Example lap 2 cell: its chunking code and spatial code during SSSS, LLSS, SSLL, and LLLL 446

trials (top to bottom respectively). 447

i—l) Chunking code correlations: (i) standard 4-lap trials (SSSS) vs LLSS trials, (j) SSSS vs SSLL 448

trials, (k) SSSS vs LLLL trials, or (l) SSLL vs LLSS trials. (331 cells, n = 6 mice). 449

N.S. denotes ‘non-significant’. See Fig. 1(l) for description and methods. 450

451

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 22: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

22

452

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 23: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

23

453

Figure 3: Chunking code tracks the sequential relationship between events and relies on 454

entorhinal input 455

a) Left: Task schedule: reward was given to the animal every lap. Right: The percentage of 456

significant chunking cells was significantly reduced in the reward-every lap task, compared with 457

the same animals running the standard 4-lap-per-trial task (Blue lines: 5 mice, χ2 =128.7, p = 0.0). 458

b) Summary statistics: Percentage of chunking cells in the whole CA1 pyramidal population that 459

were tuned to lap 1, 2, 3, or 4, during the reward every lap experiment. 460

c) Lap addition experiment: Day 1: 4-lap-per-trial experiment and Day 2: 5-lap-per-trial 461

experiment. 462

d) Chunking code correlations across the 4-lap and 5-lap experiment sessions (382 cells, n = 4 463

mice). See Fig. 1(l) for description and methods. 464

e) Two representative neurons matched across 4-lap and 5-lap experiment sessions that 465

transformed from lap 3 to lap 4 preference. 466

f) Percentage of cells that transformed from lap 3 to lap 4 preference (Blue marks: 4 mice). 467

g - j) (g) Two representative neurons matched across 4-lap and 5-lap experiment sessions that 468

transformed from lap 4 to lap 5 preference. (h) Percentage of cells that transformed from lap 4 to 469

lap 5 preference (Blue marks: 4 mice). (i) MC activity of these cells from (h) during lap 4 on day 470

1 is significantly decreased during the same lap on day 2. (j) MC activity of these cells from (h) 471

during lap 4 on day 1 is not statistically different from MC activity during lap 5 on day 2 (Mean 472

±SEM, Paired student t-test conducted). 473

k) Pearson correlation of lap 3 chunking cells’ Blue: spatial code and Orange: chunking code 474

across days during the lap addition experiment. See Fig. 1(l) for description and methods. 475

l) Left: Viral injections permitting CA1 imaging and MEC terminal inhibition in CA1, 476

simultaneously Right: During the standard 4-lap-per-trial experiment, optogenetics light-On and 477

light-Off conditions alternated every 2 trials, for a total of 32-40 trials. 478

m) Coronal section of hippocampus showing area of cortex aspiration (white line) and MEC inputs 479

labelled (red). S.L.M. = stratum lacunosum moleculare. S.P. = stratum pyramidale. 480

n) Example lap 2 cell: chunking code and spatial code during the light-Off vs light-On trials. 481

o) Chunking code correlations across light-On vs light-Off conditions (182 chunking cells, n = 3 482

mice). 483

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 24: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

24

p) Pearson correlation of Blue: spatial code and Orange: chunking code across light-On vs light-484

Off conditions, for same cells as in (o). 485

*** denotes p < 0.001, * denotes p < 0.05, N.S., not significant. 486

487

488

489

490

491

492

493

494

495

496

497

498

499

500

501

502

503

504

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 25: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

25

505

Figure 4: Chunking and spatial codes are jointly represented yet independently 506

manipulatable 507

a) Illustration: chunking and spatial codes: jointly yet orthogonally represented in the same cells. 508

b) Rotation experiment: Day 1: 4 lap experiment; Day 2: same maze experiment, rotated 90 degrees 509

relative to external cues. 510

c) Chunking code correlations across un-rotated and rotated maze session (692 cells, n = 6 mice). 511

d – e) Representative lap 1, 2, 3, and 4 neurons matched across un-rotated and rotated maze 512

sessions. 513

f) Pearson correlation of spatial code and chunking code where the maze was 90 degree rotated to 514

external cues on Day 2 as (a) (617 cells, n = 5 mice). 515

g) Pearson correlation of spatial code and chunking code across days during the standard 4-lap 516

addition experiment (404 cells in the same 5 mice as (f)). 517

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 26: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

26

518

Figure 5: The discrete chunking code is also jointly represented with continuous time code 519

a) Left: 4-lap-per trial experiment with 12s treadmill period on each lap. Right: cartoon of mouse 520

running during the treadmill period. The maze and door are not transparent in the task; shown 521

transparent here for illustration of the treadmill below. 522

b) CA1 calcium activity sorted by duration time (s) on the treadmill and lap number, normalized 523

and Gaussian smoothed (σ = 2s) (222 cells from example animal). 524

c) Trial-by-trial calcium activity of representative neurons preferring lap 1, 2, 3, and 4, temporally 525

binned calcium activity during the treadmill period (0.5s bins). Left panel: trial-by-trial calcium 526

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 27: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

27

activity; Right panel: trial averaged calcium activity (mean ±SD). Standard deviation was cut off 527

at 0 because negative activity does not exist). 528

d) Trial-by-trial calcium activity of representative neurons that do not have lap preference 529

(ordinary time cells). 530

e) Summary statistics: Percentage of chunking cells in the whole CA1 pyramidal population that 531

were tuned to lap 1, 2, 3, or 4, in the 4-lap treadmill experiment (n = 5 mice) 532

f) Chunking code correlations across between even numbered trials and odd numbered trials (243 533

cells, n = 5 mice). See Fig. 1(l) for description and methods. 534

g) Task schedule: reward was given to the animal following every lap. Every lap contains a 12s 535

treadmill period. 536

h) Summary statistics: Percentage of chunking cells in the whole CA1 pyramidal population that 537

were tuned to lap 1, 2, 3, or 4, during the reward every lap experiment (with treadmill period). 538

i) The percentage of significant chunking cells was significantly higher during the treadmill period 539

of the 4-lap-per-trial task compared with the same animals during the reward-every lap task (Blue 540

lines: 3 mice, χ2 =65.0, p = 7.8*10-16). 541

*** denotes p < 0.001, * denotes p < 0.05, N.S., not significant. 542

543

544

545

546

547

548

549

550

551

552

553

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 28: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

28

554

Figure 6: Illustration of a dinner episode 555

The dinner is organized by the chunking code around discrete events regardless of modality: 556

whether spatial (left event: being led the dinner table) or non-spatial (middle event: time waiting 557

for the food to arrive, right event: enjoying the jazz music) in nature. 558

559

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 29: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

29

560

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 30: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

30

Extended Data Fig. 1: Spatial and Reward properties of CA1 cells on the maze. 561

a) Summary of mice running in a single session of the standard 4-lap-per-trial task. Mice did not 562

miss a visit into the reward box on any run. 563

b) CA1 calcium activity sorted by spatial position and lap number, normalized and Gaussian 564

smoothed (σ = 25cm) calcium activity (3506 cells, n = 14 animals). Red label indicates reward 565

box spatial bin, and green label indicates the 100 cm long maze track. Reward box activity during 566

lap 1 (reward eating period) was excluded. 567

c) Characterization of mean spatial properties of CA1 cells active in the lap maze: Left: sparsity, 568

and Right: spatial field size, plotted mean ± SEM; n = 14 mice. In total, 72% (2509/3506) of CA1 569

cells from 14 animals were significant place cells. 570

d—e) Spatially binned calcium activity along the track (reward box, plus 16 spatial bins along 571

100cm track) showing (d) 2 representative cells that were active in response to reward, and (e) 2 572

representative place cells that did not have lap modulated activity. Left panel: trial-by-trial activity 573

Right panel: trial-averaged activity with mean ± SD. Standard deviation was cut off at 0 because 574

negative activity does not exist. 575

576

577

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 31: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

31

578

Extended Data Fig. 2: Lap 1-4 cells (more examples) 579

Representative lap 1, 2, 3, and 4 neurons, spatially binned calcium activity along the track (reward 580

box, plus 16 spatial bins along 100cm track). Left panel: trial-by-trial activity, Right trial averaged 581

activity with mean ± SD. Standard deviation was cut off at 0 because negative activity does not 582

exist. 583

584 585

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 32: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

32

586

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 33: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

33

Extended Data Fig. 3: Model correction for Speed and Head direction modulations of CA1 587 cell activity 588

a) – b) Two representative cells with calcium activity level plotted against mean animal running 589 speed (top subpanels), and head direction tuning (bottom subpanels). r denotes Pearson’s 590 correlation. 591

c) Shuffling procedure preserves the mean calcium activity level as prescribed by the linear model 592 (See Methods) (r denotes Pearson’s correlation from 14 animals). 593

594

595

596

597

598

599

600

601

602

603

604

605

606

607

608

609

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 34: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

34

610

611

Extended Data Fig. 4: The chunking code is learning dependent 612

Left: Experimental schedule for pre-trained vs post-trained animals on the standard 4-lap-per-trial 613

task. Right: The percentage of significant chunking cells was significantly less for pre-trained 614

comparing with post-trained in the same mice (Blue lines: 5 mice; χ2 =37.9, p = 7.4*10-10) 615

616

617

618

619

620

621

622

623

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 35: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

35

624

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 36: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

36

625

Extended Data Fig. 5: Chunking code preservation across sessions as calculated using raw 626 ΔF/F activity 627

a) Left: The same representative lap 1, 2, 3, and 4 neurons matched across 2 consecutive test days 628

as Fig 1j-k above, measured by raw (i.e. non-model corrected) ΔF/F calcium activity. 629

Right: Pearson correlation of chunking code across days, calculated using raw ΔF/F activity. The 630

cells here were the same animals and experimental sessions as Fig. 1l above, plotted separately for 631

lap 1, 2, 3 and 4 cell populations. 632

b) – f) Pearson correlation of chunking code across sessions, calculated using raw ΔF/F activity, 633

for the (b) fixed maze elongation experiment from Fig. 2c-f, (c) lap addition experiment from Fig. 634

3c-k, (d) random maze elongation experiment from Fig. 2g-k, (e) spatial alternation experiment 635

from Extended Data Fig. 7, and (f) maze rotation experiment from Fig. 4b-f. The cells here were 636

the same animals and experimental sessions as the corresponding plots in the main figures, plotted 637

separately for lap 1, 2, 3 and 4 cell populations. 638

639

640

641

642

643

644

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 37: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

37

645

646

Extended Data Fig. 6: Task schedule for the random maze elongation experiment 647

The first 3 consecutive trials of the random elongation experiment. Each animal underwent a 648 pseudorandom sequence of 28 consecutive 4-lap trials. Within these 28 trials, 7 trials took place 649 on the standard short maze (SSSS), and 7 trials were of each of the other 3 types SSLL, LLSS, 650 LLLL, where the maze was randomly elongated during L “long” laps. The entire 28 consecutive 651 sequence of trials was: SSSS, LLSS, LLLL, SSSS, SSSS, SSLL, SSLL, LLSS, LLLL, LLSS, 652 LLSS, SSLL, LLLL, LLLL, SSSS, LLLL, LLLL, LLSS, LLLL, LLSS, SSSS, LLSS, SSLL, SSSS, 653 SSSS, SSLL, SSLL, SSLL in this order. 654

S denotes a “short” lap and L denotes a “long” lap. 655

656

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 38: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

38

657

658

Extended Data Fig. 7: CA1 chunking cells tracks abstract “lap events” despite differential 659

spatial trajectories 660

a) Alternation experiment: Day 1: standard 4-lap experiment and Day 2: alternating trajectory 661

version. 662

b) Chunking code correlations across the standard and alternating maze sessions (371 cells, n = 4 663

mice). See Fig. 1(l) for description and methods. 664

c-d) Representative lap 1, 2, 3, and 4 neurons matched across standard and alternating maze 665

sessions. 666

667

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 39: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

39

668

Extended Data Fig. 8: Chunking cells during MEC inactivation (more examples) 669

Representative lap 1, 2, 3, and 4 neurons matched across Light-OFF and Light-ON trials. 670

671

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 40: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

40

672

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 41: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

41

Extended Data Fig. 9: Chunking code during the treadmill period 673

a) Distribution of top: animal running speed, and bottom: animal head direction during the maze 674

running portion (purple) versus the treadmill running portion (yellow) of the task, for animal 481 675

in 20 trials. 676

b) Summary data: comparison of standard deviation of top: animal running speed (tstat = 19.65, 677

df = 4, p = 4.0 * 10-5), and bottom: animal head direction (tstat = 9.32, df = 4, p = 7.4 * 10-4) 678

during the maze running portion (purple) versus the treadmill running portion (yellow) of the task, 679

for 5 animals. 680

c) CA1 calcium activity sorted by spatial position and lap number, normalized and Gaussian 681

smoothed (σ = 2s) calcium activity (1222 cells, n = 5 animals). 682

d) Representative lap 1, 2, 3, and 4 neurons, temporally binned calcium activity during the 683

treadmill period (0.5s bins). Left panel: trial-by-trial activity, Right trial averaged activity with 684

mean ± SD. Standard deviation was cut off at 0 because negative activity does not exist. 685

686

687

688

689

690

691

692

693

694

695

696

697

698

699

700

701

702

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 42: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

42

703

704

Extended Data Fig. 10: Method of image field of view registration across days 705

706

707

708

709

710

711

712

713

714

715

716

717

718

719

720

721

722

723

724

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 43: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

43

Materials and Methods 725

Animals 726

All procedures relating to mouse care and treatment conformed to the institutional and NIH 727

guidelines. Animals were individually housed in a 12 hour light (7pm-7am)/dark cycle. Nineteen 728

male Wfs1-Cre mice aged between 2-4 months were food restricted to 85-90% normal body weight 729

for the experiments. For each of the six main maze manipulation imaging experiments (fixed maze 730

elongation experiment, random maze elongation experiment, lap addition experiment, spatial 731

rotation experiment, treadmill experiment, spatial alternation experiment) the number of animals 732

used (at least 4) is indicated in the main text for each experiment. In each of these experiments, at 733

least two of these tested animals did not previously undergo any of the other manipulative 734

experiments. The other animals were experienced animals from the other manipulative 735

experiments. The exact number of animals used in each of these experiment is indicated in the text 736

directly. Three pOxr1-Cre mice, aged 2-4 months, were also implanted with Inscopix 737

microendoscope into CA1 for dual imaging and optogenetics experiments, and food restricted and 738

trained in the same manner as the Wfs1-Cre mice. 739

Histology and Immunohistochemistry 740

Mice were transcardially perfused with 4% paraformaldehyde (PFA) in phosphate buffered saline 741

(PBS). Brains were then post-fixed with the same solution for 24 hours, and brains were sectioned 742

by using a vibratome. Sections were stained by DAPI. Micrographs were obtained using a Zeiss 743

AxioImager M2 confocal microscope using Zeiss ZEN (black edition) software. 744

Preparation of Adeno-Associated Virus (AAV) 745

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 44: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

44

The AAV2/5-Syn-DIO-GCaMP6f was generated by and acquired from the University of 746

Pennsylvania Vector Core, with a titer of 1.3*10^13 genome copy/ml. The AAV2/5-CamKII-747

GCaMP6f- WPRE-SV40 was generated by and acquired from the University of Pennsylvania 748

Vector Core, with a titer of 2.3*10^13 genome copy/ml. The AAV2/2-EF1a-DIO-eNpHR3.0-749

mCherry was generated by and acquired from the University of North Carolina (Chapel Hill) 750

Vector Core, with a titer of 5.3*10^12 genome copy/ml. 751

Stereotaxic Surgery 752

Stereotactic viral injections and microendoscope implantations were all performed in accordance 753

with Massachusetts Institute of Technology (MIT)’s Committee on Animal Care guidelines. Mice 754

were anaesthetized using 500 mg/kg avertin. Viruses were injected by using a glass micropipette 755

attached to a 10 µl Hamilton microsyringe through a microelectrode holder filled with mineral oil. 756

A microsyringe pump and its controller were used to control the speed of the injection. The needle 757

was slowly lowered to the target site and remained for 10 minutes after the injection. 758

For CA1 imaging experiments, unilateral viral delivery into the right CA1 of the Wfs1-Cre mice 759

was aimed at coordinates relative to Bregma: AP: -2.0 mm, ML, +1.4 mm, DV, -1.55 mm. Wfs1-760

Cre mice were injected with 300 nl of AAV2/5-Syn-DIO-GCaMP6f. Approximately one month 761

after injection, a microendoscope was implanted into the dorsal part of CA1 of the Wfs1-Cre mice 762

aimed at coordinates relative to Bregma, at: AP: -2.0 mm, ML, +2.0 mm, and DV at approximately 763

-1.0 mm. To implant at the correct depth, the cortex was vacuum-aspirated which resulted in the 764

removal of corpus callosum, which is visible under surgery microscope as fibers running in the 765

medial-lateral direction. The fibers of the alveus, which are visible as fibers running in the anterior-766

posterior direction, were left intact by the procedure. 767

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 45: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

45

For CA1 optogenetic and imaging experiments, 300 nL (AAV2/5-CamKII-GCaMP6f- WPRE-768

SV40) unilateral viral delivery into the right CA1 of the pOxr1-Cre mice was aimed at coordinates 769

relative to Bregma: AP: -2.0 mm, ML, +1.4 mm, DV, -1.55 mm, and 300 nL (AAV2/2-EF1a-DIO-770

eNpHR3.0-mCherry) bilateral viral delivery into the MEC of these mice were aimed at coordinates 771

relative to Bregma: AP: −4.85 mm, ML, ±3.45 mm, DV, -3.35 mm. Following these virus 772

injections, the micro-endoscopy lens was implanted in the same manner for these dual optogenetic 773

and imaging experiments, as described above for CA1 imaging experiments. 774

The baseplate for miniaturized microscope camera was attached above the implanted 775

microendoscope in the mice. After experiments, animals were perfused, and post hoc analyses 776

were examined to determine actual imaging position in CA1 (Fig. 1c, Fig. 3m). 777

778

Apparatus description and Experimental conditions 779

The apparatus was a square maze 25 cm in length and width, with a 5cm wide track width, and 7 780

cm height. A 10 cm x 10 cm square reward box was located in one corner of the square maze. 781

Sugar pellets (Bio-Serve, F5684) were placed in the reward box at the beginning of lap 1 of each 782

trial. Four versions of this apparatus were used. Version 1 was used in Fig. 1-4 except Fig. 2. 783

Version 2 used in Fig. 2 had a length elongation to twice the standard length (50 cm = 2 ×25 cm), 784

but was otherwise identical to Version 1 in other dimensions. Version 3, used in Fig. 5’s treadmill 785

experiment, had a 18 cm long treadmill installed in the arm of the maze that immediately faces the 786

reward box (Fig. 5a). Version 3 otherwise used the same dimensions as Version 1. Version 4, used 787

in Extended Data Fig. 7, had an 8-maze configuration, with the other square of the 8-maze being 788

25 cm in length and width as well. Version 4 otherwise used the same dimensions as Version 1. 789

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 46: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

46

All maze experiments were done on under dim light conditions, with prominent visual cues within 790

50 cm on all sides of the box. Ca2+ imaging in the maze lasted at least 20 minutes in order to 791

collect a sufficient number of Ca2+ transients to power our statistical analyses. The maze surface 792

was cleaned between sessions with 70% ethanol. Immediately before and after imaging sessions, 793

the mouse rested on a pedestal next to the maze. 794

The basic task in this manuscript is the standard 4-lap-per-trial task, where animals traversed round 795

a square maze 25cm in length (1m journey in total) (Fig. 1d). The task was designed so that a sugar 796

pellet reward was delivered manually to the reward box, at the beginning of lap 1, once every 4 797

such laps, which we call a single ‘trial’ (Fig. 1d). Identical motions were made on each lap, 798

regardless whether a pellet was delivered or not. During the testing, animals completed 15-20 of 799

such trials in repetitive succession without interruption. For any behavioral session in which the 800

animal missed going into the reward box more than once in the entire sequence of runs (15 to 20 801

x 4 = 60 to 80 runs in total), the experiment was excluded. Crucially, for all experiments, animals 802

first underwent task training before the final testing days. Training procedures are described below: 803

804

Habituation to reward in the maze: All behavior experiments took place during the animals’ 805

dark cycle. All implanted mice were habituated to human experimenters as well as the 806

experimental room for 1 week. At the same time, they were mildly food restricted and habituated 807

to sugar pellet reward. The criterion for habituation to sugar pellets and the maze was running 808

counter-clockwise around the maze and eating a sugar pellet in the reward port of the maze 809

(described below) in 15 successive repetitions without missing a single pellet. 810

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 47: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

47

Reward periodicity-training: Animals were trained for approximately 8 days. If during any 811

training day, the mice appeared unmotivated or too satiated to complete the 15 trials, that training 812

day was repeated the following day. Animals were pre-trained for 2 days on the maze to habituate 813

to receiving sugar pellet rewards in the reward port: on each of these days, they did a 1-lap-per-814

trial task, that is, they receiving reward every run around the maze, and ran 15 such trials. For the 815

next 3 days (days 3-5), animals were trained to receive periodic rewards. On day 3, animals ran 15 816

trials of a 2-lap-per-trial task, that is, they receiving reward every 2 laps around the maze. On day 817

4, animals ran 15 trials of a 3-lap-per-trial task. On day 5, animals ran 15 trials of a 4-lap-per-trial 818

task. Finally, animals ran 3 more days (days 6-8), 15 trials per day of a 4-lap-per-trial task, before 819

they were considered well trained on the basic 4-lap-per-trial task. 820

Pre- versus Post-Training Experiment Protocol: In the particular case of the pre-versus post-821

trained animal experiment (Extended Data Fig. 4), animals that had only been habituated to the 822

reward (described above) were immediately tested/imaged by running 15 trials of the standard 4-823

lap-per-trial task. Following this initial testing, these animals then underwent the reward 824

periodicity-training (described above). Following periodicity-training, animals were tested/imaged 825

again on 15 trials of the standard 4-lap-per-trial task, to compare the chunking cells seen post-826

training, compared to pre-training. 827

Reward on every lap experiment: Animals in this experiment were given a sugar pellet on every 828

lap, completed a total of 60-80 laps total. This is equivalent to the total number of laps in the 15-829

20 trials of the 4 lap-per-trial experiment. This experiment did not require extra or task-specific 830

training. 831

832

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 48: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

48

TASK-SPECIFIC TRAINING 833

Each of the main maze manipulation experiments (fixed maze elongation experiment, random 834

maze elongation experiment, lap addition experiment, spatial rotation experiment, treadmill 835

experiment, spatial alternation experiment) required its own special ‘task’ training after completing 836

the habituation and reward periodicity-training. 837

Fixed maze elongation experiment (Fig. 2): For the fixed maze elongation experiments, animals 838

were tested/imaged in a 2-day experiment. On Day 2, 2 hours prior to experimentation, animals 839

were habituated (allowed to run) for 3 minutes on the distorted maze without any rewards. 840

Random maze elongation experiment (Fig. 2): For the random maze elongation experiment, 841

animals were tested/imaged on 28 4-lap trials. The maze was elongated on random laps of random 842

trials, such that each of the 4 types of trials (SSSS, SSLL, LLSS, LLLL, where S denotes a “short” 843

lap and L denotes a “long” lap) were presented in pseudorandom order (Extended Data Fig. 6 for 844

full schedule) and appeared 7 times each within the 28 trials. Prior to test day, animals underwent 845

3 days (days (-3) to (-1)) of habituation training to the short and long laps, where SSSS, SSLL, 846

LLSS, LLLL trials were presented randomly. 847

Five-lap-per-trial experiment (Fig. 3): For the 5-lap-per-trial experiment, animals were 848

tested/imaged in a 2-day experiment. These animals underwent 3 days (days (-3) to (-1)) of 849

habituation training before the first test day. On the first 2 training days (day-3 to -2), animals each 850

day ran 15 trials of a 5-lap-per-trial task. On the 3rd day of training, (day (-1)) animals ran 15 trials 851

of a 4-lap-per-trial task again, to get them habituated to test day. 852

Optogenetics experiment (Fig. 3): Calcium imaging used the Inscopix nVoke miniature 853

optoscope, occurring at 20 Hz. During periods of optogenetic manipulation as defined by our 854

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 49: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

49

protocol (Fig. 3l), the Inscopix nVoke miniature optoscope’s orange light (590-650 nm) 855

stimulation was turned on, at 10 mW/mm2 power, at a uniform and constant level. Orange light 856

delivery was done manually and was turned on or off at the start of the relevant trial as soon as 857

animals entered the box. 858

For optogenetic manipulation experiment, animals were tested/imaged in a single day. These 859

animals underwent 2 days of habituation training before the first test day with 2 days in between 860

each of the training days to allow recovery from the light. On each of the training days, animals 861

each day ran 16 trials of a 4-lap-per-trial task with the light schedule according to the alternating 862

schedule shown in Fig. 3l. 863

Spatial rotation experiment (Fig. 4): For the spatial rotation experiment, animals were 864

tested/imaged in a 2-day experiment. On Day 2, 2 hours prior to experimentation, animals were 865

habituated (allowed to run) for 3 minutes on the distorted maze without any rewards. 866

Treadmill experiment (Fig. 5): For the treadmill experiment, animals were tested/imaged in a 867

single day. These animals underwent 6 days of habituation training running on the maze before 868

the first test day. On the first day of training, animals ran 15 trials of a 1-lap-per-trial task. During 869

each lap, the animal ran onto the first arm of the square maze, and ran for 12s (time period 870

accurately indicated via Arduino) on the treadmill at a constant 14 cm/s, before running around 871

the rest of the square maze and entering the reward box. On the next five days of training, animals 872

ran 15 trials of a 4-lap-per-trial task again, with 12s on the treadmill, to get them habituated to test 873

day. 874

Alternation maze experiment (Extended Data Fig. 7): For the spatial alternation experiment, 875

animals were tested/imaged in a 2-day experiment. These animals underwent 5 days (days (-5) to 876

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 50: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

50

(-1)) of habituation training before the first test day. On the first 4 training days (day-5 to -2), 877

animals each day ran 15 trials of a 4-lap-per-trial task where the laps alternated in their spatial 878

trajectories according to Extended Data Fig. 7a. On the 5th day of training, (day (-1)) animals 879

underwent ran 15 trials of an ordinary (non-alternating) 4-lap-per-trial task again, to get them 880

habituated to test day. 881

882

Behavioral analysis and Ca2+ events detection 883

The animal’s position was captured by an infrared camera (Ordro infrared camcorder, 30 fps) via 884

infrared light emitting diodes (LEDs) attached to the animal. Calcium events were captured at 20 885

Hz on an Inscopix miniature microscope. Imaging sessions were time stamped to the start of the 886

behavioral recording by the turning on of an LED that is fixed to the animal, at the beginning of 887

the session, and turning off of the LED at the end. 888

Analysis of the calcium images and extraction of independent neuronal traces were done akin to 889

previous methods (30, 41). Specifically, the calcium movie was then binned 4x spatially along 890

each dimension, and then processed by custom made code written in ImageJ (dividing each image, 891

pixel by pixel, by a low-passed (r = 20 pixels) filtered version). It was then motion corrected in 892

Inscopix Mosaic software 1.2.0 (correction type: translation and rotation; reference region with 893

spatial mean (r = 20 pixels) subtracted, inverted, and spatial mean applied (r = 5 pixels)). A spatial 894

mean filter was applied to it in Inscopix Mosaic (disk radius = 3), and a ΔF/F signal was calculated. 895

Four hundred (400) cell locations were selected from the resulting movie by PCA-ICA (600 output 896

PCs, 400 ICs, 0.1 weight of temporal information in spatio-temporal ICA, 750 iterations 897

maximum, 1E-5 fractional change to end iterations) in Inscopix Mosaic software. Region of 898

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 51: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

51

interest (ROIs), half-max thresholded, that were not circular (if its length exceeded its width by > 899

2.5 times) or smaller than 5 pixels in diameter (~12 um), were discarded. For each ROI filter, 900

pixels less than 75% of the filter’s maximum intensity were zeroed. 901

ΔF/F calcium traces were calculated for the resulting ROI filters for each processed movie. Slow 902

variations in the calcium traces were eliminated by subtracting the median percentile ΔF/F value 903

at each timepoint, this value calculated from the calcium trace values ±15s within this timepoint, 904

similar to Ziv et al, 2013(30). The calcium trace was smoothed by 4-temporal bin rolling average 905

(each bin 50 ms). Significant calcium transients (Fig. 1c) were detected as traces that exceeded 3 906

Standard Deviations above baseline, and furthermore, remained above 1.5 Standard Deviations 907

above baseline for at least 500 ms. The rest of the ΔF/F calcium traced, aside from its significant 908

transients, were zeroed similar to Dombeck, 2010. Only cells that had a total of at least 25 909

significant transients during the entire session and nonzero activity in at least 10 trials separately 910

were considered for further analysis in this study. In the sole case of the treadmill experiment, a 911

lesser total of at least 10 significant transients was used, since the cumulation of all the treadmill 912

periods was only 12-16 min (15-20 trials). 913

914

Chunking cell calculation 915

A) Calcium event filtering 916

For each CA1 cell detected, the calcium activity was filtered so that only activity occurring while 917

the mice were in an active state (animal speed > 4 cm/s) were analyzed further. The behaviorally 918

tracked times of interest were also filtered in this way, considering only the times with animal 919

speed > 4 cm/s. The maze was divided into 9 spatial bins: the reward box (spatial bin of length and 920

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 52: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

52

width 10 cm) was one spatial bin, and each of the 4 arm lengths of the maze were divided in half 921

(8 spatial bins, each of which was 12.5 cm in length and 5 cm in width). 922

Next, for each identified cell, individual calcium activity epochs were analyzed by calculating the 923

mean calcium activity in each of the 9 spatial bins during each individual lap across trials. Thus, 924

for a session of 15-20 trials, there were 540 to 720 calcium activity epochs in total (15 to 20 × 9 925

×4 = 540 to 720). 926

Each CA1 neuron possesses a spatially tuning, and in this model, the spatial tuning was captured 927

by a parameter p defined as the probability of having nonzero calcium activity in each separate 928

spatial bin. p was calculated for each neuron for each of its spatial bins. It differed for different 929

spatial bins, reflecting the spatial code. 930

Linear model fitting 931

For each activity epoch for each neuron, the mean ΔF/F calcium activity, the mean speed (s), and 932

the head direction tuning (o) were calculated. The nonzero calcium activity epochs were fit by a 933

linear regression of the mean ΔF/F calcium activity versus speed and head direction tuning. In this 934

regression, the coefficients a, b, c were fit: 935

𝑅𝑅[𝐶𝐶𝐶𝐶] ~ (𝐶𝐶 ∗ 𝐬𝐬 + b ∗ 𝐨𝐨 + c) [1] 936

Where R[Ca] is the mean ΔF/F calcium activity level of this neuron during this activity epoch. s 937

is the mean speed of the animal during this activity epoch, and o is the head orientation deviation 938

from the preferred head orientation of this neuron during this activity epoch. In Matlab code, we 939

used the function: fitrlinear with lambda = 0.01, to fit the equation [1] using regularized 940

linear regression applied to the calcium activity epochs of all cells. 941

942

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 53: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

53

B) Identification of Chunking cells 943

For each identified cell, we shuffled its calcium transients across the lap epochs, such that the 944

probability of assigning any particular calcium transient into any particular lap epoch varied 945

according to equation [1]. Calcium transients were only shuffled (using randperm in matlab) 946

between different epochs taking place in the same spatial field in order to preserve p. We checked 947

that this shuffle generation procedure gave a mean ΔF/F calcium activity level that matched the 948

model-predicted (equation [1]) calcium activity level (Extended Data Fig. 3c). These shuffles 949

simulated the calcium activity of the cell explained by spatial field (p), head direction (o) and 950

animal speed (s). A total of 5000 such shuffles were computed, and a ‘model-explained mean ΔF/F 951

calcium activity level’ was computed as 952

𝑅𝑅𝑚𝑚𝑚𝑚𝑚𝑚𝑚𝑚𝑚𝑚[𝐶𝐶𝐶𝐶, 𝐿𝐿 = 𝑖𝑖, 𝑆𝑆 = 𝑗𝑗] = 𝑚𝑚𝑚𝑚𝐶𝐶𝑚𝑚(𝑅𝑅[𝐶𝐶𝐶𝐶, 𝐿𝐿 = 𝑖𝑖, 𝑆𝑆 = 𝑗𝑗])𝑠𝑠ℎ𝑢𝑢𝑢𝑢𝑢𝑢𝑚𝑚𝑚𝑚𝑠𝑠 953

Where 𝑅𝑅[𝐶𝐶𝐶𝐶,𝑅𝑅 = 𝑖𝑖, 𝑆𝑆 = 𝑗𝑗] is the ‘model-explained calcium activity’ computed as the mean 954

activity in lap i and spatial bin j across all the shuffles for this cell. 955

For every neuron on all four individual laps, the model-explained mean calcium activity level in 956

each individual spatial bin was subtracted from the real mean ΔF/F calcium activity, to yield 957

‘model corrected’ (MC) ΔF/F calcium activity which excluded spatial, mean speed, and mean head 958

direction tuning (Fig. 1h). Thus, this model corrected effect would mainly reflect difference in 959

calcium activity due to lap number. 960

For every neuron, the model-explained mean ΔF/F calcium activity level was subtracted from the 961

mean ΔF/F calcium activity level obtained from the 5000 shuffles, to yield a distribution of MC 962

ΔF/F activities for chance level statistics. Cells whose peak, lap-specific MC ΔF/F was outside the 963

95th percent confidence of shuffled MC ΔF/F were called ‘significant chunking cells’. 964

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 54: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

54

If the peak MC calcium activity happened to occur during the reward eating lap (lap 1) while the 965

animal was in the reward box spatial bin, then the peak MC calcium activity from the next highest 966

spatial bin was selected, because we excluded cell activity that was directly driven by reward 967

eating. 968

We also considered looking at raw ΔF/F activity of these chunking cells to examine if similar 969

results were obtained (Extended Data Fig. 5). 970

Spatial information 971

The tracked positions were sorted into 16 spatial bins of size 6.25cm x 5cm around the track and 972

4 spatial bins of size 5cm x 5cm in the reward box and the mean ΔF/F calcium activity of each 973

CA1 cell was determined for each bin. The bins which had animal occupancy < 100 ms were 974

considered unreliable and discarded from further analysis. Without smoothing, the spatial tuning 975

was calculated for each cell according to: 976

�𝑝𝑝𝑖𝑖𝜆𝜆𝑖𝑖 log2𝜆𝜆𝑖𝑖𝜆𝜆

𝑖𝑖

977

Where 𝜆𝜆𝑖𝑖 is the mean ΔF/F calcium activity of a unit in the i-th bin, 𝜆𝜆 is the overall ΔF/F calcium 978

activity, and pi is the probability of the animal occupying the i-th bin for all i. This formulation, 979

derived in Skaggs et al, 1993(42), was applied to calcium activity levels, which have a known 980

monotonic relationship to spike rates (Chen et al, 2013). All cells’ event times were shuffled 2000 981

times in an analogous manner to Wills et al, 2010 by shifting the calcium activity time series 982

around the position data by a random translation of > 20 s and less than the session duration minus 983

20s. Cells with significant spatial information were determined above the 95th percentile of all 984

shuffles. 985

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 55: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

55

Registering cells across days 986

Our approach to register cells across days was to do so on the basis of the anatomy of the field of 987

view seen on both days (i.e. the pattern of blood vessels, etc.), rather than on the spatial locations 988

of cells directly (Extended Data Fig. 10). Then, after an appropriate image registration was found 989

for the fields of view based on anatomy, the ROIs on day 1 were identified, and calcium traces 990

were calculated based on the resulting ROI filters for day 1 applied directly to the processed movie 991

on day 2. To register two movies across days, a mean projection of the ImageJ filtered and motion 992

corrected movie (see above methods) on each day was computed, and these two movies were 993

registered with respect to one another by the Inscopix Mosaic motion correction software. 994

Chunking and Spatial correlations across days 995

For chunking correlations across days: for a given significant chunking cell on day 1, its chunking 996

code (defined in the main text) was concatenated into a vector. A similar vector was produced for 997

this same cell on day 2. This was done for each significant chunking cell matched across days. The 998

Pearson correlation between the day 1 chunking code vector and day 2 chunking code vector was 999

calculated to examine chunking code preservation across days. The day 2 chunking code vector 1000

was produced from the same spatial bin as day 1 to allow for direct chunking code comparison, 1001

except for the spatial rotation and spatial trajectory alternation experiment. In these cases the 1002

spatial bin in which peak activity occurred were calculated anew, since the space was substantially 1003

changed in these experiments relative to room cues. 1004

For spatial correlations across days: The raw calcium events, speed filtered (> 4 cm/s) were sorted 1005

into the 9 spatial bins defined above and the calcium activity level of each neuron was determined 1006

for each bin, and an activity map composed of all the spatial bins was produced. The activity maps 1007

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint

Page 56: CA1 pyramidal cells organize an episode by segmented and ... · 1 . 1 . CA1 pyramidal cells organize an episode by segmented and ordered events 2 . Chen Sun1, *, Wannan Yang3, Jared

56

for each individual chunking cell was treated as a vector (list of numbers) and Pearson correlation 1008

between the spatial activity maps of the two days was calculated. 1009

Statistics 1010

All statistical tests in this study were two tailed. 1011

1012

.CC-BY-NC-ND 4.0 International licensecertified by peer review) is the author/funder. It is made available under aThe copyright holder for this preprint (which was notthis version posted March 5, 2019. . https://doi.org/10.1101/565689doi: bioRxiv preprint