Skip to content

Commit 7e8ee2a

Browse files
committed
fix HW script
1 parent 72c5066 commit 7e8ee2a

File tree

5 files changed

+67
-63
lines changed

5 files changed

+67
-63
lines changed

assets/images/erp_wh_bids2.png

49.6 KB
Loading

assets/images/topo_wh_bids2.png

101 KB
Loading

others/TIPS_and_FAQ.md

+38-39
Original file line numberDiff line numberDiff line change
@@ -34,18 +34,18 @@ directly manipulate signal arrays. If you intend to use the ICA toolbox
3434
functions underlying EEGLAB, EEGLAB itself is a good starting point and
3535
introduction. EEGLAB also provides a full EEG structure to describe your
3636
data (signal, trials, channel location, reaction time, type of the
37-
trials, time limits and sampling rate) and allows you use this structure
37+
trials, time limits and sampling rate) and allows you to use this structure
3838
either from the MATLAB command line or in MATLAB scripts.
3939

4040

41-
### Is MATLAB too slow and does it use too much memory ?
41+
### Is MATLAB too slow and does it use too much memory?
4242
**Answer:** Yes, to an extent, but... Because MATLAB sometimes uses large amount of RAM, we also took great care of inserting
4343
options in EEGLAB and in several processing functions to handle low
4444
memory conditions. On the other hand the MATLAB environment offers the
4545
advantage of stability and ease of use. Even the novice user under
4646
MATLAB can scale a data array by multiplying it by a scalar for instance
4747
(and in our software the data array is directly accessible to the user).
48-
MATLAB also offers the advantage of modularity. All of our function are
48+
MATLAB also offers the advantage of modularity. All of our functions, are
4949
stand-alone functions and most of them can be used independently of each
5050
other. Besides, MATLAB has grown much faster.
5151

@@ -68,7 +68,7 @@ Processing toolbox which has to be purchased separately.
6868

6969
### Overloaded functions
7070

71-
under Unix, I often get the following message
71+
Under Unix, I often get the following message
7272
''Warning: One or more output arguments not assigned during call to
7373
'XXX'.
7474

@@ -87,7 +87,7 @@ variable or rename the function.
8787

8888
- Buy more memory (RAM) for your computer
8989
- Try the memory mapping scheme (in EEGLAB options) which will allow
90-
to keep the data on disk. Note that expect for Neuroscan files, it
90+
keeping the data on disk. Note that except for Neuroscan files, it
9191
is still necessary to import the full data file in memory.
9292

9393
### Multi-core use
@@ -96,8 +96,8 @@ variable or rename the function.
9696
Does it benefit to have a multi-core machine?
9797

9898
**Answer:** yes, it benefits in two ways. First, you may start in
99-
parallel several MATLAB session. Each of them is assigned one of the
100-
processor. Second, if you go to the MATLAB options, you may have the
99+
parallel several MATLAB sessions. Each of them is assigned one of the
100+
processors. Second, if you go to the MATLAB options, you may have the
101101
option to enable multi-core computation (General \> Multithreading).
102102
This option is usually set by default. This is a very efficient option
103103
that will speed up your code usually linearly with the number of core (2
@@ -160,9 +160,9 @@ degrees, but Polhemus (Neuroscan) goes counter-clockwise and EEGLAB goes
160160
clockwise. We are trying to develop some conversion solution for this,
161161
but if
162162

163-
1. you already have some experience w/ a situation like this you may
163+
1. you already have some experience w/ a situation like this and you may
164164
have some easy solution;
165-
2. you could advice use to get our Polhemus coordinates into EEGLAB
165+
2. you could advise us on how to get our Polhemus coordinates into EEGLAB
166166
some other (easier) way, we would appreciate.
167167

168168

@@ -192,7 +192,7 @@ specified. For instance I asked for epochs between 0 and 3 seconds at
192192
125 Hz and end up with an interval of 0 to 2.992 s. There should be
193193
something wrong!
194194
**Answer:** Nothing is wrong. In your example, we must draw (125Hz \*
195-
3seconds = 375 points) and not 376 otherwise we would loose time
195+
3seconds = 375 points) and not 376 otherwise we would lose time
196196
linearity i.e. 2 epochs of 3 seconds would be 752, whereas if we draw 6
197197
seconds of the data we would get 751 points !), but if we assign time 0
198198
to the first point, then we must assign time 2.992 to the last point.
@@ -239,7 +239,7 @@ Functions
239239

240240
### Missing trials in ERPimage?
241241

242-
When using channel ERP image ('Plot' -'Channel ERP
242+
When using the ERP image menu item ('Plot' -'Channel ERP
243243
image'), the top part of the output is the window with the sorted
244244
trials. The number of the trials seems to be off and it appears that not
245245
all trials are displayed. For instance, using a file with 17 trials the
@@ -266,7 +266,7 @@ box of the pop_erpimage() interactive window.
266266

267267
### Cross-subject analysis of spectral power and coherence?
268268

269-
Do you have any good way to to across subject/patient
269+
Do you have any good way to across subject/patient
270270
analyses with respect to power and coherence, especially making
271271
statistical comparisons between subjects/patients? Could we somehow use
272272
the data output of EEGLAB?
@@ -284,13 +284,13 @@ Artifacts
284284

285285
It is not very difficult to find components related to
286286
eyeblinks, etc. In my case, there are phases during the experiment,
287-
where people speak and/or move there eyes. I find it quite hard to
287+
where people speak and/or move their eyes. I find it quite hard to
288288
determine which components are related to these artifacts and I already
289289
wonder if it is possible et all.
290-
**Answer:** To determine wich components are related to these artefacts,
290+
**Answer:** To determine wich components are related to these artifacts,
291291
one approach is to isolate these trials (selecting them) and then use
292292
menu item "Plot \> Component ERPs \> With component maps" and select the
293-
time window where these event appears. This function will plot which
293+
time window where these event appear. This function will plot which
294294
components contribute to this type of artifact. However, you are correct
295295
in thinking that ICA cannot cleanly resolve ALL artifacts into one or a
296296
few components. For instance, "paroxysmal" artifacts (like the subject
@@ -308,9 +308,9 @@ or more). Also their spectrum does not look like the standard EEG
308308
### Rejecting artifacts
309309

310310
I am currently using ica to correct for artifacts. In the
311-
past I've visually inspected each single-trial epoch seperately,
311+
past I've visually inspected each single-trial epoch separately,
312312
indentified those trials with artifact activity, and then trained ICA on
313-
each trial seperately to identify and remove artifactual components. As,
313+
each trial separately to identify and remove artifactual components. As,
314314
you can imagine this process is extremely time consuming. Is it
315315
effective to train ICA on multiple or all concatenated trials at once,
316316
remove artifactual components, and then go back to visually inspect the
@@ -377,11 +377,11 @@ data rank (see below).
377377
### Baseline removal and preparing data for ICA
378378

379379

380-
What is the rationale behind baseline zero'ing the data
380+
What is the rationale behind baseline zeroing the data
381381
before running it thru ICA, and is that always recommended?
382382

383383

384-
**Answer:** It is recomended because the EEG might have some electrical
384+
**Answer:** It is recommended because the EEG might have some electrical
385385
artifacts (slow trends) that you want to remove. If your data is
386386
perfectly flat (at very low frequencies), then you shouldn't need to do
387387
that. You should baseline-zero each epoch, else use the continuous data
@@ -391,7 +391,7 @@ associated with a series of 1-of-a-kind, non-stationary maps). The data
391391
scrolling utility in EEGLAB makes this convenient, and if you perform
392392
this on the continuous data, records breakpoint events that guide
393393
subsequent epoching. Else, you can more severely prune the data to train
394-
the ICA model, then pass more of the data through the model (at a cost
394+
the ICA model, then pass more of the data through the model (at the cost
395395
of somewhat higher SNR (signal to noise ratio) in the activation time
396396
series).
397397

@@ -410,7 +410,7 @@ Note we do not recommend using PCA (" 'pca', 4 ") unless you have some
410410
good reason. Using first PCA components only will truncate the data
411411
(irrespective of components), and then ICA may not be able to find
412412
relevant components. The second possibility ("'ncomps', 4") is more
413-
acceptable theoritically since it is a true ICA decomposition (that uses
413+
acceptable theoretically since it is a true ICA decomposition (that uses
414414
a rectangular matrix). In general, we advise finding as many components
415415
as possible (e.g. if you have enough memory on you computer to run ICA
416416
over all the channels).
@@ -437,8 +437,8 @@ to use.
437437
### ICA applied to data epochs or continuous data
438438

439439
I have noticed that the runica() does not include a field
440-
for epoch size, so how does ICA recognize the epochs ? Doesn't this make
441-
a difference to the way ICA is handled ?
440+
for epoch size, so how does ICA recognize the epochs? Doesn't this make
441+
a difference to the way ICA is handled?
442442
**Answer:** Epochs are concatenated before running ICA. In ICA, all time
443443
points of all epochs are shuffled so that epoch information is
444444
irrelevant.
@@ -451,7 +451,7 @@ epochs from the data, which are 3000 frames each. There are only about
451451
Should I apply ICA to the continuous data, then epoch the ICs, or apply
452452
ICA to the concatenated epochs?
453453
**Answer:** You can apply ICA to either of them. Usually, we prefer to
454-
apply ICA to the concatenated epochs so ICA component are more likelly
454+
apply ICA to the concatenated epochs so ICA component are more likely
455455
to represent activity related to the task, but continuous data are fine
456456
too, especially if you have few epochs or few data points, since most of
457457
the same EEG and artifact processes are likely to be active 'between'
@@ -471,7 +471,7 @@ not expressed in the data at that particular time).
471471
Time Frequency
472472
--------------
473473

474-
### Timef() spectral decompositions: properties and discrepencies
474+
### Timef() spectral decompositions: properties and discrepancies
475475

476476
Is it not true that the ERP for a condition can be
477477
completely reconstructed from the timef() results, incuding ITC? One
@@ -491,7 +491,7 @@ results ....
491491

492492
**Answer:** Yes, this is possible (with some fuzziness regarding
493493
overlap-adding the overlapping spectral estimates, undoing the effects
494-
of tapering (windowing), etc. I havent focused on strictly "invertible"
494+
of tapering (windowing), etc. I haven't focused on strictly "invertible"
495495
time/frequency transforms - which tend to be restrictive, since I am
496496
interested in analysis rather than synthesis.
497497

@@ -539,8 +539,7 @@ the plot's time scale it appears that the epoch is from slightly before
539539
-2000 ms to slightly over +1500 ms. Do you know why?
540540
**Answer:** It is normal that the time limits are different from the
541541
original dataset, since the FFT (or wavelet) is applied over time
542-
windows and we consider the center of these windows. As a result, you
543-
loose half the window size on each edge of the plot (some hundred
542+
windows and we consider the center of these windows. As a result, you lose half the window size on each edge of the plot (some hundred
544543
milliseconds depending on the window size and the sampling rate).
545544

546545
### Spectrum using FFT, Welch or multitaper
@@ -552,14 +551,14 @@ The Thomson method (usually known as multitaper) is good too. It is
552551
first projecting the data onto an orthogonal base, then performing FFT.
553552

554553
They should all return similar results (FFT, pwelch, multitaper). I
555-
guess the Thomson method is the less sensitive to noise but also the
556-
most complex to use. I guess it would also be possible to use the welch
554+
guess the Thomson method is less sensitive to noise but also
555+
more complex to use. I guess it would also be possible to use the welch
557556
method on top of multitaper. It is all a matter of preference. I would
558557
advised using the pwelch method which is easy (you just give as an
559558
option the length of the windows and the overlap). Multitaper would
560559
require you to select the number of basis vector in your othogonal base
561560
and this is much less intuitive (and also has consequences on the
562-
frequency resolution you can achive).
561+
frequency resolution you can achieve).
563562

564563
### Multitaper, FTT, wavelets for time-frequency decomposition?
565564

@@ -568,12 +567,12 @@ couple of weeks, especially timef() and crossf(). The multitaper method
568567
with bootstrap statistics has been giving me very nice stable results.
569568
Timef() with wavelets gives slightly different results, but also
570569
interesting. I noticed though that all the analysis has been designed to
571-
study coherenece, phase-coherence, ITC, etc, for data organized as
570+
study coherence, phase-coherence, ITC, etc, for data organized as
572571
epochs. (e.g. inter-trial effects).
573572

574573

575574
Is there a function for computing time-varying coherence between
576-
'independent' activation functions for continous spontaneous recordings?
575+
'independent' activation functions for continuous spontaneous recordings?
577576
(i.e., spontaneous coherence for brief windows of time, 200-300ms). J.P.
578577
Lachaux (from Varela's Lab) has several papers investigating this issue.
579578

@@ -673,8 +672,8 @@ too thick. How can I control their thickness?
673672

674673
**Answer:** To change the figure aspect for publication, you can go in
675674
the figure menu and use the MATLAB menu item "Tools \> Edit". Then you
676-
can select any object in the figure. Second button will display a
677-
contextual menu where you will be albe to change line thickness, color,
675+
can select any object in the figure. The second button will display a
676+
contextual menu where you will be able to change line thickness, color,
678677
font aspects..., or even draw additional lines or add text. We also
679678
export figures as Postcript files and open them with Adobe Illustrator
680679
in vector format to fine tune it. See also this web page.
@@ -687,7 +686,7 @@ the scroll channel data eegplot(), and for channel spectra and
687686
maps...and other plots....
688687

689688

690-
**Answer:** For most EEGLAB figures, sinply use menu item "File \>
689+
**Answer:** For most EEGLAB figures, simply use menu item "File \>
691690
Export".
692691

693692

@@ -722,11 +721,11 @@ how to fix this problem?
722721
the MATLAB command line by typing: "feature('UseGenericOpenGL',1)" For
723722
the printing error, we also experience this; it is a MATLAB problem
724723
which is not consistent between Windows and Linux. We always print or
725-
save to files (.jpg or .eps Postcript), then print the files. For
724+
save to files (.jpg or .eps Postscript), then print the files. For
726725
instance, use the software
727726
[FreeRawPrint](http://download.com.com/3001-2088-10178995.html) to send
728-
the postcript file to the printer under windows. Even with this
729-
strategy, some parts of complex figures may disapear, but this is rare
727+
the Postscript file to the printer under windows. Even with this
728+
strategy, some parts of complex figures may disappear, but this is rare
730729
(then we use screen captures, or use a Windows machine, since printing
731730
seems to be more reliable under Windows OS). We hope MATLAB will become
732731
better at this in the future (Is MATLAB listening?).

support/index.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ The pages below describe how to troubleshoot EEGLAB and get answer to your quest
1414

1515
- [Use Google](http://google.com). Write down your query and add the keyword EEGLAB or EEGLABLIST at the beginning.
1616
- Use this wiki search. At the top of this page, write down your query.
17-
- Look at the [TIPS and FAQ](/FAQ/TIPS_and_FAQ) page.
18-
- Look at the [EEGLAB filtering FAQ](/FAQ/Firfilt_FAQ) page.
17+
- Look at the [TIPS and FAQ](/others/TIPS_and_FAQ) page.
18+
- Look at the [EEGLAB filtering FAQ](/others/Firfilt_FAQ) page.
1919

2020
## Ask the community
2121

0 commit comments

Comments
 (0)