<div dir="ltr"><br><div><span style="font-family:Tahoma;font-size:13px">I'm concerned to do PCA on my dataset due to a recent conversation on the EEGlab mailing list ....</span><br></div><div><span style="font-family:Tahoma;font-size:13px"><br>
</span></div><div style><span style="font-family:Tahoma;font-size:13px">This is good to know, but in our case we don't reduce the rank of data set and we don't remove any information </span><span style="font-family:Tahoma;font-size:13px">using PCA dimension reduction</span><span style="font-family:Tahoma;font-size:13px">. So I think it should be fine. </span></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">On 9 March 2013 12:13, Peter Goodin <span dir="ltr"><<a href="mailto:pgoodin@swin.edu.au" target="_blank">pgoodin@swin.edu.au</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">





<div>
<div style="direction:ltr;font-size:10pt;font-family:Tahoma">Hi Hamid, 
<div><br>
</div>
<div>Thanks very much for the response. </div>
<div><br>
</div>
<div>I'm concerned to do PCA on my dataset due to a recent conversation on the EEGlab mailing list where Arnaud Delorme states that PCA prior to ICA may create artifacts in the data (he does say that this occurs especially in frequency space, but doesn't discount
 problems in the time series). </div>
<div><br>
</div>
<div>I'm using fastica to decompose my data as this appears to take into account the rank deficiency (especially when using tsss) through examination of data specific co-variance matrices, but thank you for the the script to use the runICA algorithm. If I have
 the time (and patience) I might do a quick exploration of PCA and runICA vs. fastICA.</div>
<div><br>
</div>
<div>Additionally, thank you for confirmation regarding using the mags to examine components. I agree, far better than attempting to decipher the grads topoplots... </div>
<div><br>
</div>
<div>Peter.</div>
<div><br>
</div>
<div><div class="im"><br>
<div><br>
<div style="font-family:Tahoma;font-size:13px">
<div style="font-family:Tahoma;font-size:13px">
<div style="font-family:Tahoma;font-size:13px">
<div><font>__________________________</font></div>
<div><font>Peter Goodin,  </font>
<div>
<div>
<div>BSc (Hons), Ph.D Candidate.</div>
<div><br>
</div>
<div><font>Brain and Psychological Sciences Research Centre (BPsych)</font></div>
<div>Swinburne University, </div>
<div>Hawthorn, Vic, 3122</div>
</div>
<div><br>
</div>
<div><font>Monash Alfred Psychiatry Research Centre (MAPrc)</font></div>
<div><font>Level 1, Old Baker Building</font></div>
<div><font>Commercial Road</font></div>
<div><font>Melbourne, Vic, 3004</font><span style="font-size:small"> </span></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div><div style="font-size:16px;font-family:Times New Roman">
<hr>
<div style="direction:ltr"><font face="Tahoma" color="#000000"><b>From:</b> <a href="mailto:fieldtrip-bounces@science.ru.nl" target="_blank">fieldtrip-bounces@science.ru.nl</a> [<a href="mailto:fieldtrip-bounces@science.ru.nl" target="_blank">fieldtrip-bounces@science.ru.nl</a>] on behalf of Hamid Mohseni [<a href="mailto:hamid.mohseni@eng.ox.ac.uk" target="_blank">hamid.mohseni@eng.ox.ac.uk</a>]<br>

<b>Sent:</b> Saturday, 9 March 2013 10:12 PM<br>
<b>To:</b> FieldTrip discussion list<br>
<b>Subject:</b> Re: [FieldTrip] ICA on neuromag data - invalid assumption of full rank data & mixed sensors?<br>
</font><br>
</div><div><div class="h5">
<div></div>
<div>
<div dir="ltr">Hi Peter,
<div><br>
</div>
<div>Regarding your first question: after  maxfilter, you need to do a pca, simply because your rank of data has been reduced from 306 to about 64. You can do this by:</div>
<div><br>
</div>
<div>
<div>cfg        = [];</div>
<div>cfg.method = 'runica'; </div>
<div>n_comp = rank(squeeze(data.trial{1}) * squeeze(data.trial{1})');</div>
<div>cfg.runica.pca = n_comp;</div>
<div>cfg.runica.stop = 1e-7;</div>
<div>comp = ft_componentanalysis(cfg, data);<br>
</div>
<div><br>
</div>
<div>Here, n_comp is the number of component and it is equal to the rank of data set. If you don't do this, the algorithm takes a long time and normally does not converge. Note that the data should be continuous and it is highly recommended to remove
 big and jump artefacts before ICA (for example using ft_databrowser). I found ICA using infomax 'runica' quite robust with high accuracy fro removing EOG and ECG.</div>
<div><br>
</div>
<div><br>
</div>
<div>Regarding your second question: Using only 'MAG' to investigate the topograph of component is fine, and better than 'GRAD', but have a look at the components time-series as well. If you remove that component it will be removed from the whole data
 set.<br>
</div>
<div><br>
</div>
<div><br>
</div>
</div>
</div>
<div class="gmail_extra"><br>
<br>
<div class="gmail_quote">On 9 March 2013 01:56, Peter Goodin <span dir="ltr"><<a href="mailto:pgoodin@swin.edu.au" target="_blank">pgoodin@swin.edu.au</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>
<div style="direction:ltr;font-size:10pt;font-family:Tahoma">Hi Fieldtrip list, 
<div><br>
</div>
<div>Firstly I'd like to thank those who have asked questions using ICA on neuromag 306 data and the answers given. It's been extremely informative and taught me a lot about the general principles of ICA (it's no longer completely black magic, only partially...).<br>

<br>
I have two and a bit questions about using ICA on neuromag data, the first on the full rank assumption. After maxfiltering, the output data is rank deficient due to removal of the b-out components. I see that fastica is able to detect this and makes adjustments
 to the amounts of components extracted accordingly, but is doing this justified? What actually happens to the data if ICA is applied to a rank deficient data set? Are there any papers that examine this? </div>
<div><br>
</div>
<div>Secondly, I've been including all the meg channels (mags + grads) when running ICA (due to my interpretation of the conversation in <a href="http://mailman.science.ru.nl/pipermail/fieldtrip/2012-April/005016.html" target="_blank">http://mailman.science.ru.nl/pipermail/fieldtrip/2012-April/005016.html</a>)
 then examining the time series components for those related to artifact (specifically ECG and EOG), while using a magnetometer only layout to view component topographies as a backup. My question (well, really a confirmation) is, by removing the artifact components
 calculated using the mixed sensors, does this remove the associated components from all the sensor types? Viewing pre and post ICA data appears to confirm this, but expert opinion is always good. The bit of a question is - is it acceptable to use a magnetometer
 only layout to interpret topoplots of the components if the components are based on mixed sensors? I've been using it because the readily identifiable artifact components have a distribution I'd expect from ECG and EOG as does the associated time series but
 I'm wanting to make sure.  </div>
<div><br>
</div>
<div>Also, if this is the wrong forum to ask these questions can someone suggest one that might be a better fit? </div>
<div><br>
</div>
<div>Thanks again, </div>
<div><br>
</div>
<div>Peter.<br>
<div><br>
<div style="font-family:Tahoma;font-size:13px">
<div style="font-family:Tahoma;font-size:13px">
<div style="font-family:Tahoma;font-size:13px">
<div><font>__________________________</font></div>
<div><font>Peter Goodin,  </font>
<div>
<div>
<div>BSc (Hons), Ph.D Candidate.</div>
<div><br>
</div>
<div><font>Brain and Psychological Sciences Research Centre (BPsych)</font></div>
<div>Swinburne University, </div>
<div>Hawthorn, Vic, 3122</div>
</div>
<div><br>
</div>
<div><font>Monash Alfred Psychiatry Research Centre (MAPrc)</font></div>
<div><font>Level 1, Old Baker Building</font></div>
<div><font>Commercial Road</font></div>
<div><font>Melbourne, Vic, 3004</font><span style="font-size:small"> </span></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
_______________________________________________<br>
fieldtrip mailing list<br>
<a href="mailto:fieldtrip@donders.ru.nl" target="_blank">fieldtrip@donders.ru.nl</a><br>
<a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br>
</blockquote>
</div>
<br>
<br clear="all">
<div><br>
</div>
-- <br>
Hamid R. Mohseni, PhD<br>
Post-Doctoral Research Assistant<br>
Institute of Biomedical Engineering<br>
University of Oxford, OX3 7DQ, UK<br>
Tel: <a href="tel:%2B44%20%280%29%201865%202%2083826" value="+441865283826" target="_blank">+44 (0) 1865 2 83826</a><br>
</div>
</div>
</div></div></div>
</div>
</div>
</div>

<br>_______________________________________________<br>
fieldtrip mailing list<br>
<a href="mailto:fieldtrip@donders.ru.nl">fieldtrip@donders.ru.nl</a><br>
<a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Hamid R. Mohseni, PhD<br>
Post-Doctoral Research Assistant<br>Institute of Biomedical Engineering<br>University of Oxford, OX3 7DQ, UK<br>Tel: +44 (0) 1865 2 83826<br>
</div>