Closed juthzi closed 3 years ago
Hi,
That is odd... Is it possible that when that participant was run they got an extra trial? I have not run into this problem processing EDFs before.
Can you send me the EDF file in question and the code you are using?
Hi jgeller112,
thanks for taking a look at this. The experimental code does not allow for more than 96 trials. Also, when I run the function 'find_messages_edf()', I get the correct amount of trials.
You can download the respective EDF file here: https://uni-koeln.sciebo.de/s/ZoqDiNjczxc1Sln
The code I am using is the following:
# set the path to edfs
directory_edf = '/Users/jzimmermann/Desktop/HANNA/Hanna_pupillen_auswertung/edf'
# set the path where csv files should be stored
directory_csv_from_edf_conversion = "../csv"
# get list of edf files
file_list_edf <- list.files(path = directory_edf, pattern = '.EDF')
# ...change the working directory to where your data is held
setwd('/Users/jzimmermann/Desktop/HANNA/Hanna_pupillen_auswertung/edf')
# parse edfs and saves them into directory
parse_edf(file_list = file_list_edf, output_dir = directory_csv_from_edf_conversion, type = "pupil")
Can you re-send the file link? I cant download it anymore.
Yes, of course. I time-limited it. Here it is again:
So it looks like an issue within the EDF file itself and not the gazeR function. Can you pass the file through Data Viewer and see if it parses the correct number of trials? I do not have access to the full version of Data Viewer to do this.
The message function does not use the trial column included in the sample report of the EDF to parse trials, but instead uses messages to do this. This is why there is a discrepancy between parse_edf and parse_messages. It is possible that in the EDF file there is an erroneous extra trial thrown in there.
My suggestion would be to remove the first trial.
Thank you very much! Indeed, it seems there was a first trial logged, which should not be there. I agree, that I should remove it. I cannot check the number of trials in Data Viewer at the moment (working at home), but will do so when I can.
Just to add: I checked the number of trials in Data Viewer. It finds 97 as well. However, the first trial it identifies, does not refer to the actual first trial.
Glad we solved that problem!
Hello everyone,
I use the parse_edf function, which outputs the csv file with the expected number of trials (96) for most of my participants. However, for one subject, it outputs 97 trials. The number of logs of 'TRIALID' in that participant seems to be 96, however, so I do not know why this happens.
Thank you for any help regarding the issue.