subject.py
activate(schema_name, *, create_schema=True, create_tables=True, linking_module=True)
¶
Activate this schema.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
schema_name |
str
|
schema name on the database server to activate the
|
required |
create_schema |
bool
|
when True (default), create schema in the database if it does not yet exist. |
True
|
create_tables |
bool
|
when True (default), create tables in the database if they do not yet exist. |
True
|
linking_module |
bool
|
a module name or a module containing the |
True
|
required |
dependencies to activate the `subject` element
|
|
required |
Dependencies:
Upstream tables
Source: The source of the material/resources (e.g. allele, animal) - typically refers to the vendor (e.g. Jackson Lab - JAX) Lab: The lab for which a particular animal belongs to Protocol: the protocol applicable to a particular animal (e.g. IACUC, IRB) User: the user associated with a particular animal
Source code in element_animal/subject.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | |
Strain
¶
Bases: dj.Lookup
Genetic strain of an animal. (e.g. C57Bl/6).
Attributes:
| Name | Type | Description |
|---|---|---|
strain |
varchar(32)
|
Abbreviated strain name. |
strain_standard_name |
varchar(32)
|
Formal name of a strain. |
strain_desc |
varchar(255)
|
Optional. Description of this strain. |
Source code in element_animal/subject.py
56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 | |
Allele
¶
Bases: dj.Lookup
Store allele information.
Attributes:
| Name | Type | Description |
|---|---|---|
allele |
varchar(32)
|
Abbreviated allele name. |
allele_standard_name |
varchar(255)
|
Optional. Standard name of an allele. |
Source code in element_animal/subject.py
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |
Source
¶
Bases: dj.Part
Source of an allele.
Attributes:
| Name | Type | Description |
|---|---|---|
Allele |
foreign key
|
Allele key. |
source_identifier |
varchar(255)
|
ID of the provider. |
source_url |
varchar(255)
|
Optional. URL to the source information |
expression_data_url |
varchar(255)
|
Optional. Link to the expression pattern from Allen institute brain atlas. |
Source code in element_animal/subject.py
89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |
Line
¶
Bases: dj.Lookup
Genetic line.
Attributes:
| Name | Type | Description |
|---|---|---|
line |
varchar(32)
|
Abbreviated name for the line. |
species |
varchar(64)
|
Latin name preferred for NWB export. |
line_description |
varchar(2000)
|
Optional. Description of the line. |
target_phenotype |
varchar(255)
|
Optional. Targeted gene phenotype. |
is_active |
boolean)
|
Whether the line is in active breeding. |
Source code in element_animal/subject.py
109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 | |
Allele
¶
Bases: dj.Part
Allele of the line.
Attributes:
| Name | Type | Description |
|---|---|---|
Line |
foreign key
|
Line key. |
Allele |
foreign key
|
Allele key. |
Source code in element_animal/subject.py
130 131 132 133 134 135 136 137 138 139 140 141 | |
Subject
¶
Bases: dj.Manual
Animal subject information.
Attributes:
| Name | Type | Description |
|---|---|---|
subject |
varchar(8)
|
Subject ID. |
subject_nickname |
varchar(8)
|
Subject nickname. |
sex |
enum
|
'M', 'F', or 'U'; Male, Female, or Unknown. |
subject_birth_date |
date
|
Birth date of the subject. |
subject_description |
varchar(1024)
|
Description of the subject. |
Source code in element_animal/subject.py
144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 | |
Protocol
¶
Bases: dj.Part
Protocol under which this subject animal is used.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
Protocol |
foreign key
|
Protocol key. |
Source code in element_animal/subject.py
165 166 167 168 169 170 171 172 173 174 175 176 | |
User
¶
Bases: dj.Part
Individual responsible for experiment or management of the subject.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
User |
foreign key
|
User key. |
Source code in element_animal/subject.py
178 179 180 181 182 183 184 185 186 187 188 189 | |
Line
¶
Bases: dj.Part
Genetic line of the subject.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
Line |
foreign key
|
Line key. |
Source code in element_animal/subject.py
191 192 193 194 195 196 197 198 199 200 201 202 203 | |
Strain
¶
Bases: dj.Part
Genetic strain of the subject.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
Strain |
foreign key
|
Strain key. |
Source code in element_animal/subject.py
205 206 207 208 209 210 211 212 213 214 215 216 217 | |
Source
¶
Bases: dj.Part
Source (e.g., vendor) of the subject.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
Source |
foreign key
|
Source key. |
Source code in element_animal/subject.py
219 220 221 222 223 224 225 226 227 228 229 230 231 | |
Lab
¶
Bases: dj.Part
Lab where the subject belongs.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
Lab |
foreign key
|
Lab key. |
subject_alias |
varchar(32)
|
Alias for lab if different from id. |
Source code in element_animal/subject.py
233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 | |
SubjectDeath
¶
Bases: dj.Manual
Subject death information.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
date_date |
date)
|
Death date. |
Source code in element_animal/subject.py
250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
SubjectCull
¶
Bases: dj.Manual
Subject culling information.
Attributes:
| Name | Type | Description |
|---|---|---|
SubjectDeath |
foreign key
|
SubjectDeath key. |
cull_method |
varchar(255)
|
Optional. Culling method (e.g., cervical dislocation) |
cull_reason |
varchar(255)
|
Optional. Reason for culling. |
cull_notes |
varchar(1000)
|
Optional. Description of the culling. |
Source code in element_animal/subject.py
266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 | |
Zygosity
¶
Bases: dj.Manual
Information about zygosity of a subject.
Attributes:
| Name | Type | Description |
|---|---|---|
Subject |
foreign key
|
Subject key. |
Allele |
foreign key
|
Allele key. |
zygosity |
Present or Absent or Homozygous or Heterozygous
|
Similarity of an allele. |
Source code in element_animal/subject.py
286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 | |