What is the ideal way to read conditions into the timing file?
July 18, 2023 10:31AM
Are the task conditions listed in the txt conditions file stored in the TrialRecord structure? I would like to have my timing file read in some properties of the conditions but I cannot find the conditions in either TrialRecord or MLConfig. Currently I call the conditions file directly in my timing file using
T = table2cell(readtable('cond_file.txt')) but this is not ideal as it requires changing the timing file every time the condition file name is changed.

The reason I am doing this is to track progress on a subset of conditions during the task.
Re: What is the ideal way to read conditions into the timing file?
July 19, 2023 11:07AM
I figured out one solution after posting the Q and leaving it here in case anybody else wanted to do this. To access the contents of my conditions file from the timing file, I created a folder (cond_folder) that only contains the conditions file (cond_file.txt) and then in the timing file I call it using dir()

cond_folder= dir('cond_folder');
cond_file = cond_folder(end).name;
T = table2cell(readtable(cond_file ));
Re: What is the ideal way to read conditions into the timing file?
July 20, 2023 04:44PM
If what you want is just the filename of the conditions file, you can retrieve it from MLConfig.
cond_file = MLConfig.MLPath.ConditionsFile;

The National Institute of Mental Health (NIMH) is part of the National Institutes of Health (NIH), a component of the U.S. Department of Health and Human Services.