> For the complete documentation index, see [llms.txt](https://docs.neuroinfodb.org/squirrel/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.neuroinfodb.org/squirrel/specifications/specification-v1.0/data/subjects/studies.md). Agents can also search and read this documentation through its [MCP server](https://docs.neuroinfodb.org/squirrel/~gitbook/mcp).

# studies

JSON array

An array of imaging studies, with information about each study. An imaging study (or imaging session) is defined as a set of related series collected on a piece of equipment during a time period. An example is a research participant receiving an MRI exam. The participant goes into the scanner, has several MR images collected, and comes out. The time spent in the scanner and all of the data collected from it is considered to be a study.

Valid squirrel **modalities** are derived from the DICOM standard and from NiDB modalities. Modality can be any string, but some squirrel readers may not correctly interpret the modality or may convert it to “other” or “unknown”. See full list of [modalities](https://docs.neuroinfodb.org/squirrel/specifications/specification-v1.0/modalities.md).

<figure><img src="https://mermaid.ink/img/pako:eNqVlEFvgjAUx78KqSHBRBazsAtLPG2XZdmSeVu4POlDOoGStmwS43dfSykKelAO9P3b37-vfU85kJRTJDHZCqhz7_0rqTz9CM5V8Lb-_OiieRiuKCgIzGv-fEL0fA3pDrYY9ON0ldVYsAplMEQTAvc1ClZipWRwFk8okzikLFWMVyDaYKLnFu5mw9VW8KaGCopW6sSd8px0-_aobDY_mOrULnDrThtGNZTpjfrxCsE3EsUvmMPI4FxcYVml9LK-YgeP1EDbRCa1LofJ3A2Xy_ZSTAYucIjvW0v4YBokoJQZK0yPTOigS9QUxYBy1GjfP-uLwU7SwiftdRNz5xt63p2jF9bj1MThLmIMLrYGp0aG4QqqLdAbjm-YIp5lWbbQ1RJ8hyEFmYMQ0MaPY9Moyz3GSRXusY5KcYtxYh86eovXevofzWDAp-VyYS3xLIqiPg7_GFV5HNV7siAlihIY1R-Hg9kqISrHEhMS65BiBk2hEpJUR402tS4-vlKmuCBxBoXEBYFG8XVbpSRWokEHvTDQ35rSTeo_6jfnZW86_gPjwJGq?type=png" alt=""><figcaption></figcaption></figure>

### JSON variables

:blue\_circle: Primary key\
:red\_circle: Required\
:yellow\_circle: Computed (squirrel writer/reader should handle these variables)

<table data-full-width="true"><thead><tr><th width="186" align="right">Variable</th><th width="151">Type</th><th width="101">Default</th><th>Description</th></tr></thead><tbody><tr><td align="right"><code>AgeAtStudy</code></td><td>number</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f534">🔴</span></td><td>Subject’s age in years at the time of the study.</td></tr><tr><td align="right"><code>DayNumber</code></td><td>number</td><td></td><td>For repeated studies and clinical trials, this indicates the day number of this study in relation to time 0.</td></tr><tr><td align="right"><code>Description</code></td><td>string</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f534">🔴</span></td><td>Study description.</td></tr><tr><td align="right"><code>Equipment</code></td><td>string</td><td></td><td>Equipment name, on which the imaging session was collected.</td></tr><tr><td align="right"><code>Height</code></td><td>number</td><td></td><td>Height in <strong>meters</strong> of the subject at the time of the study.</td></tr><tr><td align="right"><code>Modality</code></td><td>string</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f534">🔴</span></td><td>Defines the type of data. See table of supported <a href="https://docs.neuroinfodb.org/squirrel/specifications/specification-v1.0/modalities.md">modalities</a>.</td></tr><tr><td align="right"><code>Notes</code></td><td>string</td><td></td><td>Any notes about the study.</td></tr><tr><td align="right"><code>StudyDatetime</code></td><td>datetime</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f534">🔴</span></td><td>Datetime of the study.</td></tr><tr><td align="right"><code>StudyNumber</code></td><td>number</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f534">🔴</span> <span data-gb-custom-inline data-tag="emoji" data-code="1f535">🔵</span></td><td>Study number. May be sequential or correspond to NiDB assigned study number.</td></tr><tr><td align="right"><code>StudyUID</code></td><td>string</td><td></td><td>DICOM field <code>StudyInstanceUID</code>.</td></tr><tr><td align="right"><code>TimePoint</code></td><td>number</td><td></td><td>Similar to day number, but this should be an ordinal number.</td></tr><tr><td align="right"><code>VisitType</code></td><td>string</td><td></td><td>Type of visit. ex: Pre, Post.</td></tr><tr><td align="right"><code>Weight</code></td><td>number</td><td></td><td>Weight in <strong>kilograms</strong> of the subject at the time of the study.</td></tr><tr><td align="right"><code>AnalysisCount</code></td><td>number</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f7e1">🟡</span></td><td>Number of analyses for this study. Only written if the study has analyses.</td></tr><tr><td align="right"><code>SeriesCount</code></td><td>number</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f7e1">🟡</span></td><td>Number of series for this study. Only written if the study has series.</td></tr><tr><td align="right"><code>VirtualPath</code></td><td>string</td><td><span data-gb-custom-inline data-tag="emoji" data-code="1f7e1">🟡</span></td><td>Relative path to the data within the package.</td></tr><tr><td align="right"><a href="https://docs.neuroinfodb.org/squirrel/specifications/specification-v1.0/data/subjects/studies/series.md">series</a></td><td>JSON array</td><td></td><td>Array of series.</td></tr><tr><td align="right"><a href="https://docs.neuroinfodb.org/squirrel/specifications/specification-v1.0/data/subjects/studies/analysis.md">analyses</a></td><td>JSON array</td><td></td><td>Array of analyses.</td></tr></tbody></table>

### Directory structure

Files associated with this section are stored in the following directory. `SubjectID` and `StudyNum` are the actual subject ID and study number, for example `/data/S1234ABC/1`. If `StudyDirectoryFormat` is `seq`, a sequential number is used instead of the study number.

> `/data/<SubjectID>/<StudyNum>`


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.neuroinfodb.org/squirrel/specifications/specification-v1.0/data/subjects/studies.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
