Skip to content

Code for the manuscript "Complete representation of action space and value in all striatal pathways", https://www.biorxiv.org/node/1217451.abstract

License

Notifications You must be signed in to change notification settings

wegmor/striatum-2choice

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This repository contains the python code that generated the figures in the publication "Complete representation of action space and value in all striatal pathways", available on bioRxiv. The associated data files can be found here.

  • endoData_2019.hdf includes the CaImAn-extracted calcium traces and behavioral data (operant chamber logs, DeepLabCut-tracked coordinates).
  • alignment_190227.hdf includes ROI-mappings across days as well as the ROI spatial filters as images.

How to recreate our figures

Create an isolated python environment and install the required packages using conda.

$ conda create -n striatum-2choice python=3.8.3
$ conda activate striatum-2choice
$ conda install -c conda-forge cython numpy pandas scipy scikit-learn statsmodels h5py \
  tqdm scikit-image pillow matplotlib seaborn deprecated pytables opencv pims pip
$ pip install cmocean figurefirst

Git-clone the repository or download it as a zip file and unpack.

git clone https://github.com/wegmor/striatum-2choice.git

Navigate to the top of the repository folder structure and create a data subfolder. Copy the data files endoData_2019.hdf and alignment_190227.hdf into the data folder.

Each figure is generated by its own python script. The figures will be saved to a subfolder svg. Many of the figures require substantial, preparatory computation (12+ hours, e.g. due to 1,000 bootstrapping steps); the results of this preprocessing are stored in a cache folder as pickle files.

To generate any figure, activate the conda environment ($ conda activate striatum-2choice), navigate to the top of the repository folder structure, and run the associated python script ($ python figureX.py). Each figure is created by its one python script, with a name starting with figure followed by the figure number.

Reference

Weglage, M., Wärnberg, E., Lazaridis, I., Tzortzi, O., & Meletis, K. (2020). Complete representation of action space and value in all striatal pathways. bioRxiv, 2020.03.29.983825. https://doi.org/10.1101/2020.03.29.983825

About

Code for the manuscript "Complete representation of action space and value in all striatal pathways", https://www.biorxiv.org/node/1217451.abstract

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages