Skip to content

Commit

Permalink
Fix process_nst_separations
Browse files Browse the repository at this point in the history
The process was not working when the optodes index didn't match optodes names
  • Loading branch information
Edouard2laire committed Jul 5, 2019
1 parent fa5642d commit e988cfd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bst_plugin/process_nst_separations.m
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@
montage_info = nst_montage_info_from_bst_channels(channels);
separations = zeros(size(pair_indexes, 1), 1);
for ipair=1:size(pair_indexes, 1)
src_idx = montage_info.src_ids == pair_indexes(ipair, 1);
det_idx = montage_info.det_ids == pair_indexes(ipair, 2);
src_idx = montage_info.src_ids == montage_info.src_ids(pair_indexes(ipair, 1));
det_idx = montage_info.det_ids == montage_info.det_ids(pair_indexes(ipair, 2));
separations(ipair) = euc_dist(montage_info.src_pos(src_idx, :), ...
montage_info.det_pos(det_idx, :));
end
Expand Down

0 comments on commit e988cfd

Please sign in to comment.