Codes and example data for the paper 'Directional dynamics in the entorhinal cortex driven by behavioral constraints'.
MATLAB (R2022a) on a Windows computer was used for all testing.
Required toolboxes: Communications Toolbox, Statistics and Machine Learing Toolbox.
No additional installation steps are needed.
- Unzip the
example_data.rarfile and place the extracted files into theexample_datadirectory. - Navigate to the
codesdirectory. The scripts corresponding to each figure are listed below. - For a quick start, please see demo.mlx (~5 mins).
| Related figures | Basic info | Folder | Script(s) used |
|---|---|---|---|
| Figure 2b-d | Calculate cell-pair correlation matrices | /imaging | calculate_cellpair_correlation_matrices.m |
| Figure 5 | Create spatially/HD-locked shuffled instances | /imaging | spatially_HD_locked_shuffle.m |
| Figure 5f-g | Calculate theta of each field | /imaging | calculate_theta.m |
| Extended Data Fig.2a-b | Compare the autocorrelogram of calcium signals and HD | /imaging | comparison_calcium_HD.m |
| Extended Data Fig.3c-i | Downsample behavior data to match speed | /behavior | downsample_speed.m |
| Extended Data Fig.4b | Calculate directionality | /behavior | calculate_directionality.m |