<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="margin:0px;font-size:15px;font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;color:rgb(32, 31, 30);background-color:rgb(255, 255, 255)">Hi Jan-Mathijs, </span></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;"><br>
</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;">Based on discussions with colleagues, I was expecting typical lead fields to be on the scale of 1e-15, and I thought lead field units should be in units of Teslas. If I am misinterpreting it,
 what would a typical brain lead field look like after using an LCMV Beamformer? </span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;"><br>
</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;">The system we collect data is on a CTF 151-channel system. So I'm not sure exactly how to modify the analyses. Any guidance here would be appreciated. In its current implementation, we had the
 source and head model in 'cm', and the coordinate system in 'mm'.</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;"><br>
</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;">My gut feeling is that the units are in T/cm as you described, so it is confusing to get it to T/m. I will look further into "<span style="background-color:rgb(255, 255, 255);display:inline !important">ft_prepare_leadfield",
 but I am also looking into the nested functions within there. You made a good point about Marc's last note being 8 years old, so a lot of these issues may have been taken care of through the years. </span></span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;"><br>
</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;">If you would be able to help figure out what units these lead fields and dipole moments are expressed in, that would be helpful. It can clarify a lot of our doubts on our end. I am relatively
 new to such analyses, so I appreciate any help. </span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;"><br>
</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;">Thank you. </span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;"><br>
</span></font></div>
<div style=""><font color="#201f1e"><span style="font-size: 15px;">Jasen</span></font></div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> fieldtrip <fieldtrip-bounces@science.ru.nl> on behalf of Schoffelen, J.M. (Jan Mathijs) via fieldtrip <fieldtrip@science.ru.nl><br>
<b>Sent:</b> May 2, 2022 3:36 AM<br>
<b>To:</b> FieldTrip discussion list <fieldtrip@science.ru.nl><br>
<b>Cc:</b> Schoffelen, J.M. (Jan Mathijs) <janmathijs.schoffelen@donders.ru.nl><br>
<b>Subject:</b> Re: [FieldTrip] Lead Field Units in LCMV Beamformer</font>
<div> </div>
</div>
<div>
<div style="display:none!important; visibility:hidden; font-size:1px; color:#ffffff; line-height:1px; max-height:0px; max-width:0px; opacity:0; overflow:hidden">
Hi Jasen, When you state that the scale is ‘much too large’ that suggests that you have a specific expectation of the values that you typically get (using other software? what is the unit convention in that software?). Since you are not clear
</div>
<div style="display:none!important; visibility:hidden; font-size:1px; color:#ffffff; line-height:1px; max-height:0px; max-width:0px; opacity:0; overflow:hidden">
</div>
<style>
<!--
#x_pfptBannerav3wag9
        {display:block!important;
        visibility:visible!important;
        opacity:1!important;
        background-color:#D0D8DC!important;
        max-width:none!important;
        max-height:none!important}
-->
</style>Hi Jasen,
<div class=""><br class="">
</div>
<div class="">When you state that the scale is ‘much too large’ that suggests that you have a specific expectation of the values that you typically get (using other software? what is the unit convention in that software?). Since you are not clear on what type
 of MEG system you have been working with, I cannot comment on the figure you report. (as a side note, if you are working with Elekta data (and MEG field gradients), if I recall well you need to read in the gradiometer description specifying the ‘coilaccuracy’
 option to be >=1 for the units to work well enough, otherwise the units may indeed be ill-defined).</div>
<div class=""><br class="">
</div>
<div class="">
<div>Besides, the physical units of (MEG) leadfields should be something like T/nAm, or (T/m)/nAm etc. , so I am not sure why you mention the scale to be of ‘1e-10 T’. </div>
<div><br class="">
</div>
<div>This being said, correctly dealing with units is tricky, since different MEG/EEG vendors have different unit conventions (e.g. metric distances expressed in cm/m/mm, potentials expressed in muV or V etc). FieldTrip aims to work internally with SI units
 (i.e. m V T etc). To this end, it tries to apply the required scaling based on the specified units in the (metadata), or based on educated guesses from the dataformat. Also, FT tries hard to synchronize the units of the different data objects that are required
 for the computation (volume conductor, gradiometers)</div>
<div><br class="">
</div>
<div>However - to complicate things a bit more - , FieldTrip data structures (e.g. gradiometer descriptions with coil positions, gradient baseline lengths, and volume conductor models) are typically broadcasted to the user with units that may not be SI (e.g.
 MEG gradients in T/cm, volume conductor models in mm).</div>
<div><br class="">
</div>
<div>By the way, if you want to explore this further, I’d recommend you to compute the leadfields using ft_prepare_leadfield, since in this way you are closer to the actual computation (while still relying on FieldTrip’s bookkeeping functionality). Note that
 Marc’s e-mail on the discussion forum is already 8 years old, and I am pretty sure that quite some things have changed (for the better) in the mean time.  </div>
<div><br class="">
</div>
<div>At this moment, I don’t see the need (yet) for any modification to the code, and I suggest that you explore a bit further, based on the above. </div>
<div><br class="">
</div>
<div>Best wishes,</div>
<div>Jan-Mathijs</div>
<div><br class="">
</div>
<div><br class="">
<blockquote type="cite" class="">
<div class="">On 25 Apr 2022, at 15:30, Jasen Devasagayam via fieldtrip <<a href="mailto:fieldtrip@science.ru.nl" class="">fieldtrip@science.ru.nl</a>> wrote:</div>
<br class="x_Apple-interchange-newline">
<div class="">
<div class="x_elementToProof" style="font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">Hello Everyone, </span><br class="">
</div>
<div dir="ltr" class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<br class="">
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
I ran into some confusion when looking at LCMV beamformed data, using the function, "ft_sourceanalysis". We are using a single shell forward model in these analyses. When looking at the output struct from this function, the lead fields were on the scale of
 1e-10 T,  which seems much too large for MEG fields. Looking into FieldTrip archives, I found a similar question by Marc Lalencette from 2014 (<a href="https://urldefense.com/v3/__https://mailman.science.ru.nl/pipermail/fieldtrip/2014-September/008438.html__;!!D0zGoin7BXfl!8ajmEDfI5wL5fN4OSXedJSEn-PVa5eFeyD01jJ6amW1ywmru-EfJdiKHpjLS7yxPP_us3QngQX0OGjeLcoDljQ95Fe-2JQR8fQ$" id="LPlnk894919" class="">https://mailman.science.ru.nl/pipermail/fieldtrip/2014-September/008438.html</a>)
 where it looks like the issue stems from the fact that fields are computed with respect to 'cm'. </div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<br class="">
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
I applied a conversion factor, by multiplying all data by 1e-4, to get from 'cm^2' to 'm^2'. I applied this conversion factor in the function "ft_compute_leadfield" in Line 260: </div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">      lf = lf*headmodel.forwpar.scale^2*1e-4;</span><br class="">
</div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><br class="">
</span></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">I had originally tried to just adjust the scaling factor, but making that one small change severely altered the data in multiple places in our pipeline, which in turn yielded
 lead fields on the scale of 1e-10 once again. In this case, the scaling factor is 1. </span></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><br class="">
</span></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">I was wondering if this would be the correct place and method to implement this modification. If not, would you have any suggestions on how to get sensible lead field values? </span></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt"><br class="">
</span></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">Thank you. </span></div>
<div class="x_x_elementToProof" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<br class="">
</div>
<div class="">
<div class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<br class="">
</div>
<div id="x_x_Signature" class="">
<div class="">
<div class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
</div>
<div class=""></div>
<div class=""></div>
<div class=""></div>
<div class="" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<table class="" style="border-collapse:collapse; border:none">
<tbody class="">
<tr class="" style="height:87.3pt">
<td width="235" class="" style="width:176.1pt; border-style:none solid none none; border-right-width:1pt; border-right-color:windowtext; padding:0cm 5.4pt; height:87.3pt">
<div class="" style="margin:0cm; font-size:12pt; font-family:Calibri,sans-serif; text-align:center">
<span lang="EN-US" class=""><span id="x_cid:202c3e90-7ada-4ef9-9785-989c31436ce8"><Outlook-rebpi3hn.png></span> </span></div>
</td>
<td width="300" valign="top" class="" style="width:225.1pt; border:none; padding:0cm 5.4pt; height:87.3pt">
<div class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<b class=""><span lang="EN-US" class="" style="font-size:13pt; font-family:Arial,sans-serif">Jasen Devasagayam</span></b><b class=""><span lang="EN-US" class="" style="font-size:9pt; font-family:Arial,sans-serif">, MASc</span></b></div>
<div class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<span lang="EN-US" class="" style="font-size:9pt; font-family:Arial,sans-serif">Research MEG Technologist </span></div>
<div class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<span lang="EN-US" class="" style="font-size:9pt; font-family:Arial,sans-serif">Neurosciences and Mental Health </span></div>
<p class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<span lang="EN-US" class="" style="font-size:7pt; font-family:Arial,sans-serif"> </span></p>
<div class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<span lang="EN-US" class="" style="font-size:9pt; font-family:Arial,sans-serif">The Hospital for Sick Children </span></div>
<div class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<span lang="EN-US" class="" style="font-size:9pt; font-family:Arial,sans-serif">686 Bay St., Toronto, ON M5G 0A4 </span></div>
<div class="" style="margin:0cm 0cm 0cm 8.1pt; font-size:12pt; font-family:Calibri,sans-serif; line-height:19.200000762939453px">
<span lang="EN-US" class="" style="font-size:9pt; font-family:Arial,sans-serif"><span lang="EN-US" class="" style="margin:0px; font-size:9pt; background-color:rgb(255,255,255); line-height:16.8px; font-family:Arial,Arial_EmbeddedFont,Arial_MSFontService,sans-serif; font-variant-ligatures:none!important"><span class="" style="margin:0px">P 416-813-7654
 ext. 201535</span></span><span class="" style="margin:0px; font-size:9pt; background-color:rgb(255,255,255); line-height:16.8px; font-family:Arial,Arial_EmbeddedFont,Arial_MSFontService,sans-serif"> </span> </span></div>
<div class="" style="margin:0cm 0cm 0cm 5.4pt; font-size:12pt; font-family:Calibri,sans-serif">
<span lang="EN-US" class=""><a href="https://urldefense.com/v3/__https://www.instagram.com/sickkidstoronto/__;!!HJOPV4FYYWzcc1jazlU!_z-ur50qPdLAjDHYrdazjQumNhsOgHecva_beSA8RIZl4a1SHJdPrXCut_sNSh9JLEXshzdkRn3cFz69mkrlSAMNKcNqFNy4XWVpig$" title="https://www.instagram.com/sickkidstoronto/" class=""><span id="x_cid:66729eed-08e2-4094-ac07-df806e63bec9"><Outlook-3fzlys2n.png></span></a><span class=""> </span><a href="https://urldefense.com/v3/__https://twitter.com/SickKidsNews__;!!HJOPV4FYYWzcc1jazlU!_z-ur50qPdLAjDHYrdazjQumNhsOgHecva_beSA8RIZl4a1SHJdPrXCut_sNSh9JLEXshzdkRn3cFz69mkrlSAMNKcNqFNy8JEWS3A$" title="https://twitter.com/SickKidsNews" class=""><span id="x_cid:6c8229b1-f31a-40f6-81d2-9e3f6dc03b93"><Outlook-anx2aeuu.png></span></a><span class=""> </span><a href="https://urldefense.com/v3/__https://www.youtube.com/channel/UCleVfdmpkf7H5tnRRw7n39A__;!!HJOPV4FYYWzcc1jazlU!_z-ur50qPdLAjDHYrdazjQumNhsOgHecva_beSA8RIZl4a1SHJdPrXCut_sNSh9JLEXshzdkRn3cFz69mkrlSAMNKcNqFNz8sQdooQ$" title="https://www.youtube.com/channel/UCleVfdmpkf7H5tnRRw7n39A" class=""><span id="x_cid:fec4544c-1823-496d-a1e4-50b6625981d9"><Outlook-j5bhmd4s.png></span></a><span class=""> </span><a href="https://urldefense.com/v3/__https://www.linkedin.com/company/the-hospital-for-sick-children/?originalSubdomain=ca__;!!HJOPV4FYYWzcc1jazlU!_z-ur50qPdLAjDHYrdazjQumNhsOgHecva_beSA8RIZl4a1SHJdPrXCut_sNSh9JLEXshzdkRn3cFz69mkrlSAMNKcNqFNzzvsrwpw$" title="https://www.linkedin.com/company/the-hospital-for-sick-children/?originalSubdomain=ca" class=""><span id="x_cid:fa53b7fd-41cc-4873-84e5-0b180b81f6f8"><Outlook-psrt3plh.png></span></a> </span></div>
</td>
</tr>
</tbody>
</table>
<br class="">
</div>
</div>
</div>
</div>
</div>
<br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<hr class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<font face="Arial" color="Gray" size="1" class="" style="font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; text-decoration:none"><br class="">
This e-mail may contain confidential, personal and/or health information(information which may be subject to legal restrictions on use, retention and/or disclosure) for the sole use of the intended recipient. Any review or distribution by anyone other than
 the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies.<br class="">
</font><span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">_______________________________________________</span><br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">fieldtrip
 mailing list</span><br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="https://urldefense.com/v3/__https://mailman.science.ru.nl/mailman/listinfo/fieldtrip__;!!D0zGoin7BXfl!8ajmEDfI5wL5fN4OSXedJSEn-PVa5eFeyD01jJ6amW1ywmru-EfJdiKHpjLS7yxPP_us3QngQX0OGjeLcoDljQ95Fe___WeMCQ$" class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<a href="https://urldefense.com/v3/__https://doi.org/10.1371/journal.pcbi.1002202__;!!HJOPV4FYYWzcc1jazlU!_z-ur50qPdLAjDHYrdazjQumNhsOgHecva_beSA8RIZl4a1SHJdPrXCut_sNSh9JLEXshzdkRn3cFz69mkrlSAMNKcNqFNxqoASfaA$" class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px">https://urldefense.com/v3/__https://doi.org/10.1371/journal.pcbi.1002202__;!!HJOPV4FYYWzcc1jazlU!_z-ur50qPdLAjDHYrdazjQumNhsOgHecva_beSA8RIZl4a1SHJdPrXCut_sNSh9JLEXshzdkRn3cFz69mkrlSAMNKcNqFNxqoASfaA$</a><span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important"></span></div>
</blockquote>
</div>
<br class="">
</div>
</div>
<br>
<hr>
<font face="Arial" color="Gray" size="1"><br>
This e-mail may contain confidential, personal and/or health information(information which may be subject to legal restrictions on use, retention and/or disclosure) for the sole use of the intended recipient. Any review or distribution by anyone other than
 the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies.<br>
</font>
</body>
</html>