Colony#

Ingest the colony database into datajoint

wehrdj.ingest.colony.MOUSE_DB_MAP = {'DOB': 'subject_birth_date', "Date Sac'd": 'death_date', 'Protocol': 'protocol', 'Sex': 'sex', 'Unnamed: 0': 'subject'}#

Mapping between values in our database and names in the datajoint model

class wehrdj.ingest.colony.MouseDB(data=None, index: Axes | None = None, columns: Axes | None = None, dtype: Dtype | None = None, copy: bool | None = None)[source]#

Trivial subtype of dataframe to indicate this is a mouse db dataframe

wehrdj.ingest.colony.insert_subjects(mousedb: wehrdj.ingest.colony.MouseDB)[source]#

Insert the loaded subject database into the datajoint database.

wehrdj.connect() must have already been called.

Parameters

mousedb (MouseDB) – the loaded mouse database

wehrdj.ingest.colony.load_mouse_db(path: pathlib.Path) wehrdj.ingest.colony.MouseDB[source]#

Load the mouse database from a .csv export of the “Mice” sheet from the colony database

Parameters

path (pathlib.Path) – The path of the csv exported from google sheets

Returns

MouseDB