Menu

Loading Data into EP

Help
2020-01-22
2020-01-27
  • Emily Perkins

    Emily Perkins - 2020-01-22

    Hi there,

    This is a super basic question, but I am using ERP PCA Toolkit for the first time and trying to load my data in. In the 'read data' window, I entered that it was in text files, is of average type, and is in single file mode (subject 3:5, cell 6:9). All of my data are in text files with names like "ER105AngA". When I click "read," I get the following error message:

    "Reference to non-existent field 'sess'.

    Error in ep>readFiles (line 11161)
    sessPosStr=get(theHandles.sess,'string');

    Error in ep (line 4217)
    readFiles(theHandles,importFormat,dataType);

    Error while evaluating UIControl Callback."

    Any advice for how to handle this error and move forward? : )

    Thank you!
    -Emily

     
  • Joe Dien

    Joe Dien - 2020-01-22

    Sorry about this! There were some bugs that got by my testing. I'll be posting a bugfix update later today I think. I'm sending you my current build. Let me know if you run into any more issues!

     
  • Emily Perkins

    Emily Perkins - 2020-01-23

    Thank you so much! I really appreciate it. Another question: I'm now at the point where I'm suppose to load in my .ced file. I had to edit the .ced file because one electrode was reappropriated to another location during collection of all subjects, but EP (reasonably) doesn't seem to like that it's now a .txt file. Any idea how to save it out in a format EP will like?

    Another related issue of my own creation is that I accidentally left the VEOG and HEOG channels in there when exporting my data from BVA. I added them to the .ced file as well, just leaving them as 0s across the board (as it seems to be in BVA) since they don't really have a location on the head, so maybe their inclusion is part of the problem with the .ced/.txt file? Do you think I should just re-export all my data, or is there some way to avert this issue by changing the .ced file, do you think? I totally understand if this is outside the purview of the EP help forum but just wanted to see if you had any insight. Thank you so much for your help!

     
  • Joe Dien

    Joe Dien - 2020-01-23

    no problem! A .ced file really is just a text file with a .ced at the end of the name rather than a .txt. EEGlab is pretty picky about that but I suppose I could modify EP Toolkit so it doesn't care about the suffix. Anyway, just rename it. You may need to set the OS to Show the Suffix as sometimes they are set to be invisible, making the suffixes even more mysterious. As for the VEOG and HEOG, you can set them to BAD. See the tutorial. If they are referenced to the the same reference as the rest of the data, you should keep them. If they are bipolar referenced (i.e., the difference between two EOG channels) then you should get rid of them. If you keep them, you should estimate their coordinates. EEGlab has a function for doing that.

     
  • Emily Perkins

    Emily Perkins - 2020-01-23

    Ah, thank you! The suffix was indeed hiding. They're bipolar channels, so I'll just re-export them (was just trying to avoid it since my computer moves at a snail's pace). I really appreciate your quick and thorough response!!

     
  • Emily Perkins

    Emily Perkins - 2020-01-24

    Hi again, sorry to ask a million questions and thank you again for your help thus far. I'm still erroring out on the loading-in-ced-file step, and I think it's probably because of the reference. For one dataset I'm working with, I average-referenced, and for the other, it's mastoid-referenced. For both datasets, everything is already processed and I'm inputting averages. I'm not sure how to indicate what the reference is in the .ced file. In the tutorial, you say that this is indicated in the final column of the .ced file, but in mine, the last column is sph_radius. Should I add another column of some sort that includes REF for the two mastoid electrodes? Do you have an example of what this should look like? Also, how to handle the average reference (list everything as REF?)?

    Trying to load in the average-referenced one without any indication of the reference in the .ced file, I get the following output. Any advice would be very much appreciated!! Thank you so much!!

    Loading summary information about datasets in working set (The more datasets in the working set, the longer this will take).
    Done loading summary information.
    According to your settings, the first file(ER105AngA) is for:
    Subject: 105
    Cell: AngA
    Loading the ced file: K:\Emily\BrainProducts-10-20_32channel_Emily.ced.txt
    Type field missing from ced file. Will assume all channels are EEG channels.
    Note: No reference channel was found.
    The name of the experiment is:
    The pre-stimulus period of the data is: 0 msec.
    Note that the data file format (text) is unable to specify the baseline period so it may be in error, in which case you will need to manually fix it using the Edit function.
    Error using cell/setdiff>cellsetdiffR2012a (line 291)
    Input A of class cell and input B of class cell must be cell arrays of character vectors, unless one is a character vector.

    Error in cell/setdiff (line 83)
    [varargout{1:nlhs}] = cellsetdiffR2012a(varargin{:});

    Error in ep_mergeEPfiles (line 429)
    if ~isempty(setdiff(data.freqNames(i),uniqueFreqNames))

    Error in ep>readFiles (line 11440)
    [EPdata, eloc]=ep_mergeEPfiles(inArg,fullMergeName);

    Error in ep (line 4236)
    readFiles(theHandles,importFormat,dataType);

    Error while evaluating UIControl Callback.

     
    • Joe Dien

      Joe Dien - 2020-01-24

      see the electrodes directory for examples

      Sent from my iPhone

      On Jan 24, 2020, at 15:59, Emily Perkins eperkins@users.sourceforge.net wrote:

      
      Hi again, sorry to ask a million questions and thank you again for your help thus far. I'm still erroring out on the loading-in-ced-file step, and I think it's probably because of the reference. For one dataset I'm working with, I average-referenced, and for the other, it's mastoid-referenced. For both datasets, everything is already processed and I'm inputting averages. I'm not sure how to indicate what the reference is in the .ced file. In the tutorial, you say that this is indicated in the final column of the .ced file, but in mine, the last column is sph_radius. Should I add another column of some sort that includes REF for the two mastoid electrodes? Do you have an example of what this should look like? Also, how to handle the average reference (list everything as REF?)?

      Trying to load in the average-referenced one without any indication of the reference in the .ced file, I get the following output. Any advice would be very much appreciated!! Thank you so much!!

      Loading summary information about datasets in working set (The more datasets in the working set, the longer this will take).
      Done loading summary information.
      According to your settings, the first file(ER105AngA) is for:
      Subject: 105
      Cell: AngA
      Loading the ced file: K:\Emily\BrainProducts-10-20_32channel_Emily.ced.txt
      Type field missing from ced file. Will assume all channels are EEG channels.
      Note: No reference channel was found.
      The name of the experiment is:
      The pre-stimulus period of the data is: 0 msec.
      Note that the data file format (text) is unable to specify the baseline period so it may be in error, in which case you will need to manually fix it using the Edit function.
      Error using cell/setdiff>cellsetdiffR2012a (line 291)
      Input A of class cell and input B of class cell must be cell arrays of character vectors, unless one is a character vector.

      Error in cell/setdiff (line 83)
      [varargout{1:nlhs}] = cellsetdiffR2012a(varargin{:});

      Error in ep_mergeEPfiles (line 429)
      if ~isempty(setdiff(data.freqNames(i),uniqueFreqNames))

      Error in ep>readFiles (line 11440)
      [EPdata, eloc]=ep_mergeEPfiles(inArg,fullMergeName);

      Error in ep (line 4236)
      readFiles(theHandles,importFormat,dataType);

      Error while evaluating UIControl Callback.

      Loading Data into EP

      Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/erppcatoolkit/discussion/767176/

      To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

       
  • Joe Dien

    Joe Dien - 2020-01-25

    error had nothing to do with the ced. I'm sending you a fix.

     
  • Emily Perkins

    Emily Perkins - 2020-01-25

    Thank you so much! Everything else has worked great, but I have one more question. I am currently trying to perform AutoPCA using the Window tab, and it is using a variance minimum of .005. I would like it to use .001 and set this preference under File --> Preferences --> Window, but it does not seem to be applying, even though I clicked save. Any advice for getting this to work? Thank you!

     
  • Joe Dien

    Joe Dien - 2020-01-27

    I took a look and it seemed to work fine. Please give more information. When you say "not applying" what exactly are you doing and what exactly are you seeing on the screen? For example, what you said could mean "I changed the number but it didn't remember the change when I checked it again" or it could mean "when I ran autoPCA it reported using the original .005 number" or it could mean "when I ran autoPCA it reported using the .001 number but didn't actually use that as the threshold" or any number of things. I need you to be more precise before I can help you.

     
  • Emily Perkins

    Emily Perkins - 2020-01-27

    OK, sorry about the lack of precision. The other day, it was remembering that I changed the Min Factor Variance number to .001 when I went back to it, but when I ran AutoPCA, it said "There are (x) factors that meet the minimum variance criterion of: 0.005." Now, however, it is working properly (0.001) when I do the same thing. Must have been my error-- sorry about that. Thanks for your time!

     

Log in to post a comment.