ronenno1 / chap

http://in.bgu.ac.il/en/Labs/CNL/chap
8 stars 7 forks source link

Error when reading .dat files #2

Closed HanZhang-psych closed 4 years ago

HanZhang-psych commented 5 years ago

Hello,

First of all, great project! I have the following error when reading .dat files:

Error using arrayfun
Non-scalar in Uniform output, at index 1, output 1.
Set 'UniformOutput' to false.

Error in dat2matlab (line 96)
    trial_data.Trial_Onset_num = arrayfun(@(timestamp) get_trial_data_start(timestamp, timestamps),
    event_timestamps(trial_ids));

Error in read_data.read_file (line 41)
                full_data_mat = dat2matlab(full_name, output_folder_name, log);

Error in chap>read_raw_file (line 30)
    data = read_data.read_file(log);

Error while evaluating UIControl Callback.

After setting 'UniformOutput' to false, I get the following error:

Undefined operator '-' for input arguments of type 'cell'.

Error in dat2matlab (line 102)
    trial_data.trial_length    = (trial_data.Trial_Offset_num-trial_data.Trial_Onset_num);

Error in read_data.read_file (line 41)
                full_data_mat = dat2matlab(full_name, output_folder_name, log);

Error in chap>read_raw_file (line 30)
    data = read_data.read_file(log);

Error while evaluating UIControl Callback.

I have attached my toy dataset below. data file https://drive.google.com/file/d/1_A4xZLUN6h27rI9Uu_rEGEmUE5zu3lRw/view?usp=sharing event file https://drive.google.com/file/d/1EyyXgWFLcv0XSLe04cX-4vFdh6TzKtJy/view?usp=sharing

The data was recorded by PyGaze + Eyelink under Remote setting.

Thanks for your help!

HanZhang-psych commented 5 years ago

I think I found a solution. There must be some data existing before the timestamp of TRIALID.

QJieWang commented 2 years ago

I have met the same question.