[FieldTrip] Units for dipole moment retrieved through ft_dipolefitting

Nunez Ponasso, Guillermo gcnunez at wpi.edu
Wed May 15 04:07:39 CEST 2024


Dear FieldTrip community,

I am using the function ft_dipolefitting to retrieve the dipole position and moment from simulated EEG readings using my own forward solver (so I know the true solution).

First I created the raw data as follows:

raw = [];
raw.datatype = 'raw';
raw.time={zeros(1,Ntime_samples)};
raw.iseeg='yes';
raw.label=labels;
raw.chanunit='V';
raw.senstype='eeg';
raw.trial = {repmat(ElectrodeVoltages,1,Ntime_samples)};

for i = 0:(Ntime_samples-1)
    raw.time{1}(i+1)=i/Ntime_samples;
end

if ft_datatype(raw,'raw')
    disp("Raw data created succesfully.")
end

Where ElectrodeVoltages is an N_electrodes x 1 vector with values in Volts (V).

After this is done I do the following:

disp("Dipole fit with real initial value")
cfg = [];
cfg.numdipoles = 1;
cfg.gridsearch = 'no';
cfg.headmodel = head_model;
cfg.dip.pos = dip0.dip.pos;
cfg.elec=elec;

dip = ft_dipolefitting(cfg, raw);
disp("Dipole fit completed!")

Here, dip0.dip is the original dipole, for which I have the position dip0.dip.pos and moment information dip0.dip.mom. In other words, I do a dipole fit with the true dipole position as the intial position. The head model is a 3-layer model with millimeter units (mm).

Here is the structure that I get for dip.dip:

>> dip.dip

ans =

  struct with fields:

     pos: [-16.4780 -12.0334 47.4920]
     mom: [3×10 double]
     pot: [256×10 double]
      rv: [1.2740e-04 1.2740e-04 1.2740e-04 1.2740e-04 1.2740e-04 1.2740e-04 1.2740e-04 1.2740e-04 … ]
    unit: 'mm'

The distance and orientation of the fitted dipole are very close to the distance and orientation of the original dipole.

Now, the issue is that the moment of my original dipole is Ampere times meter (A m). But I don't know how I should interpret the output dipole moment. The only clue is the field dip.dip.unit ('mm').

If the units are Amperes times millimeters (A mm), then the difference between both dipole moments is very large. However, if the units are milli Amperes times millimeter (mA m), then we have very good agreement.

How can I know what are the units of the output?

Thank you!

Guillermo Nunez Ponasso
Post-doc, Electrical Engineering. WPI

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20240515/859b5300/attachment.htm>


More information about the fieldtrip mailing list