Hi Giuseppe,
You can use the function cs_convert to get the MNI coordinates in “Brainstorm coordinates”:
http://neuroimage.usc.edu/brainstorm/CoordinateSystems#Converting_between_coordinate_systems
P_scs = cs_convert(sMri, ‘mni’, ‘scs’, P_mni); % MNI coordinates => SCS
Then look for the close electrode:
[minDist, iClosest] = min(sum(bsxfun(@minus, [ChannelMat.Channel.Loc], P_scs’) .^ 2, 1));
Cheers,
Francois