Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] OASIS-to-BIDS is not up to date with online data #1321

Merged
merged 6 commits into from
Oct 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion clinica/iotools/bids_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,7 @@ def create_participants_df(

fields_bids = ["participant_id"]
prev_location = ""
prev_sheet = 0
index_to_drop = []
subjects_to_drop = []
study_name = StudyName(study_name)
Expand Down Expand Up @@ -387,7 +388,7 @@ def create_participants_df(
tmp = field_location[i].split("/")
location = tmp[0]
# If a sheet is available
sheet = tmp[1] if len(tmp) > 1 else ""
sheet = tmp[1] if len(tmp) > 1 else 0
# Check if the file to open for a certain field is the same of the previous field
if location == prev_location and sheet == prev_sheet:
pass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,7 @@ def create_sessions_dict(
# Load the file
tmp = field_location[i].split("/")
location = tmp[0]
if len(tmp) > 1:
sheet = tmp[1]
else:
sheet = ""

sheet = tmp[1] if len(tmp) > 1 else 0
file_to_read_path = clinical_data_dir / location
file_ext = os.path.splitext(location)[1]
if file_ext == ".xlsx":
Expand Down
78 changes: 39 additions & 39 deletions clinica/iotools/converters/specifications/participant.tsv
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
Field BIDS CLINICA BIDS format BIDS type AIBL AIBL location OASIS OASIS location OASIS3 OASIS3 location
BIDS id of the participant participant_id Keyword 'sub-' followed by one of the original subject IDs without special characters or symbols string
Second participant id alternative_id_1 string RID aibl_ptdemog_*.csv ID oasis_cross-sectional.csv Subject oasis3_participants.csv
Third participant id alternative_id_2 string
Fourth participant id alternative_id_3 string
Type of subj in PrevDemAls dataset prevdemals_status A or R (A = patients, R = relatives) char
Date of birth date_of_birth YYYY-MM-DD HH:MM:SS string PTDOB aibl_ptdemog_*.csv
Sex sex M or F char PTGENDER aibl_ptdemog_*.csv M/F oasis_cross-sectional.csv M/F oasis3_participants.csv
Educational level education_level Free format string Educ oasis_cross-sectional.csv Education oasis3_participants.csv
Deceased deceased Y or N
Age in years age_bl In years with, possibly, decimals float Age oasis_cross-sectional.csv ageAtEntry oasis3_participants.csv
Civil status marital_status Free format string
adni_rid
Site in which the patient was studied site Free format string SITEID aibl_ptdemog_*.csv
original_study
cdr CDR oasis_cross-sectional.csv cdr oasis3_participants.csv
Diagnosis at baseline diagnosis_bl AD=Alzheimer's disease - bvFTD=behavioral variant Fronto Temporal Dementia string CDR oasis_cross-sectional.csv cdr oasis3_participants.csv
Score of mmse test at the baseline mmse_bl
APOE (number of E4 alleles) apoe4 0, 1 or 2 (number of E4 alleles) int
apoe_gen1 APGEN1 aibl_apoeres_*.csv
apoe_gen2 APGEN2 aibl_apoeres_*.csv
prevdemals_age_at_onset_patients In years with, possibly, decimals float
Laterality of the subject laterality Hand oasis_cross-sectional.csv Hand oasis3_participants.csv
inclusion_date YYYY-MM-DD HH:MM:SS string
prevdemals_parent_transmitting_ftd Y or N char
prevdemals_parent_transmitting_als Y or N char
prevdemals_parent_transmitting father or mother string
Indicate if the genotype is mutated or not prevdemals_genetic_status_mutated Y (mutated) or N (not mutated) bool
prevdemals_aoo_transmitting_parent in years
prevdemals_family_phenotype_als Y or N
prevdemals_family_phenotype_ftd Y or N
Average age onset disease in all the family member prevdemals_aoo_mean_family float
prevdemals_expected_years_aoo_bl signed float
age_first_symptoms
clinad_inclusion
clinad_final_inclusion
prevdemals_distance_aoo_transmitting_parent
prevdemals_family_code
BIDS id of the participant participant_id Keyword 'sub-' followed by one of the original subject IDs without special characters or symbols string
Second participant id alternative_id_1 string RID aibl_ptdemog_*.csv ID oasis_cross-sectional-5708aa0a98d82080.xlsx Subject oasis3_participants.csv
Third participant id alternative_id_2 string
Fourth participant id alternative_id_3 string
Type of subj in PrevDemAls dataset prevdemals_status A or R (A = patients, R = relatives) char
Date of birth date_of_birth YYYY-MM-DD HH:MM:SS string PTDOB aibl_ptdemog_*.csv
Sex sex M or F char PTGENDER aibl_ptdemog_*.csv M/F oasis_cross-sectional-5708aa0a98d82080.xlsx M/F oasis3_participants.csv
Educational level education_level Free format string Educ oasis_cross-sectional-5708aa0a98d82080.xlsx Education oasis3_participants.csv
Deceased deceased Y or N
Age in years age_bl In years with, possibly, decimals float Age oasis_cross-sectional-5708aa0a98d82080.xlsx ageAtEntry oasis3_participants.csv
Civil status marital_status Free format string
adni_rid
Site in which the patient was studied site Free format string SITEID aibl_ptdemog_*.csv
original_study
cdr CDR oasis_cross-sectional-5708aa0a98d82080.xlsx cdr oasis3_participants.csv
Diagnosis at baseline diagnosis_bl AD=Alzheimer's disease - bvFTD=behavioral variant Fronto Temporal Dementia string CDR oasis_cross-sectional-5708aa0a98d82080.xlsx cdr oasis3_participants.csv
Score of mmse test at the baseline mmse_bl
APOE (number of E4 alleles) apoe4 0, 1 or 2 (number of E4 alleles) int
apoe_gen1 APGEN1 aibl_apoeres_*.csv
apoe_gen2 APGEN2 aibl_apoeres_*.csv
prevdemals_age_at_onset_patients In years with, possibly, decimals float
Laterality of the subject laterality Hand oasis_cross-sectional-5708aa0a98d82080.xlsx Hand oasis3_participants.csv
inclusion_date YYYY-MM-DD HH:MM:SS string

prevdemals_parent_transmitting_ftd Y or N char
prevdemals_parent_transmitting_als Y or N char
prevdemals_parent_transmitting father or mother string
Indicate if the genotype is mutated or not prevdemals_genetic_status_mutated Y (mutated) or N (not mutated) bool

prevdemals_aoo_transmitting_parent in years
prevdemals_family_phenotype_als Y or N
prevdemals_family_phenotype_ftd Y or N
Average age onset disease in all the family member prevdemals_aoo_mean_family float
prevdemals_expected_years_aoo_bl signed float
age_first_symptoms
clinad_inclusion
clinad_final_inclusion
prevdemals_distance_aoo_transmitting_parent
prevdemals_family_code
Loading
Loading