Instrument#
- class spark.inst.Inst#
Bases:
Enum
A SPARK instrument.
- static from_code(inst_code: str) Inst #
Retrieves an instrument by its code.
- Parameters:
inst_code – The code of the instrument to retrieve.
- Returns:
The corresponding Inst enum member.
- Raises:
ValueError – If the inst_code does not match any Inst member.
- static get(spark_pathname: str, instruments: list[Inst] = None) dict[str, DataFrame] #
Reads the specified instruments from disk given the SPARK data release directory.
- Parameters:
spark_pathname – The SPARK data release pathname.
instruments – A list of instruments to read. If None, all instruments will be read.
- Returns:
A dictionary mapping instrument codes to their respective dataframes.
- get_filepath(spark_pathname: str) Path #
Generates the filepath for an instrument using the provided SPARK data release directory.
The date string is extracted from the SPARK pathname, and is joined with the instrument’s base filepath separated by a hyphen.
- Parameters:
spark_pathname – The SPARK data release directory, which should end with a date delimited by an underscore.
- Returns:
The filepath for the instrument.
- read_csv(spark_pathname: str)#
Reads the instrument from disk given the SPARK data release directory.
- Parameters:
spark_pathname – The SPARK data release pathname.
- Returns:
A dataframe containing the instrument data.
- ACI#
Approximated-cognitive impairment
- ADI#
Area Deprivation Index (ADI)
- ADOS_2_1#
Autism Diagnostic Observation Schedule version 2 (ADOS-2) module 1
- ADOS_2_2#
Autism Diagnostic Observation Schedule version 2 (ADOS-2) module 2
- ADOS_2_3#
Autism Diagnostic Observation Schedule version 2 (ADOS-2) module 3
- ADOS_2_4#
Autism Diagnostic Observation Schedule version 2 (ADOS-2) module 4
- ADOS_2_T#
Autism Diagnostic Observation Schedule version 2 (ADOS-2) module T
- ADOS_O_1#
Autism Diagnostic Observation Schedule original version (ADOS) module 1
- ADOS_O_2#
Autism Diagnostic Observation Schedule original version (ADOS) module 2
- ADOS_O_3#
Autism Diagnostic Observation Schedule original version (ADOS) module 3
- ADOS_O_4#
Autism Diagnostic Observation Schedule original version (ADOS) module 4
- ASR#
Adult Self-Report (ASR)
- BHA#
Background History Questionnaire - Adult (BHA)
- BHC#
Background History Questionnaire - Child (BHC)
- BHS#
Background History Questionnaire - Sibling (BHS)
- BMS#
Basic Medical Screening Questionnaire
- CBCL_1_5#
Child Behavior Checklist for ages 1.5 to 5 years (CBCL/1-5)
- CBCL_6_18#
Child Behavior Checklist for ages 6 to 18 years (CBCL/6-18)
- CDV#
Core Descriptive Variables (CDV)
- CLR#
Clinical Lab Results (CLR)
- DCDQ#
Developmental Coordination Disorder Questionnaire (DCDQ)
- IQ#
Intellectual Quotient data (IQ)
- IR#
Individuals Registration (IR)
- RBSR#
Repetitive Behavior Scale - Revised (RBS-R)
- ROLES#
Roles
- SCQ#
Social Communication Questionnaire (SCQ)
- SRGD#
Self-Reported Genetic Diagnosis (SRGD)
- SRS_2_ASR#
Social Responsiveness Scale - 2; Adult Self-Report (SRS-2)
- SRS_2_DA#
Social Responsiveness Scale - 2; Adult Self-Report (SRS-2)
- SRS_2_SA#
Social Responsiveness Scale - 2; Adult Self-Report (SRS-2)
- V3#
Vineland Adaptive Behavior Scales - 3rd Edition (Vineland-3)
- property base_filepath: str#
The base filepath of the instrument, which is used to construct the full filepath.
The base filepath may contain a directory.
- Returns:
The base filepath of the instrument.
- property code: str#
The instrument code, a unique identifier of the instrument.
- Returns:
The instrument code.
- property final_score_feature: Feat | None#
The final score feature of the instrument.
- Returns:
The final score feature, or None if the instrument does not have a final score feature.