Calculate path length between scouts

Hi experts,
I have a question
For functional connectivity analysis between regions i and j when using scouts, I want to extract Regional efficiency through scouts with the following formula:
formula
Here Li,j is the minimum path length between regions i and j. How I can calculate or extract this value through Brainstorm?

best regard,

I'm sorry, we have no solutions for this problem.
You would need to implement it yourself as a Matlab script.

The Scripting tutorial: contains everything you need to learn how to get started with scripting in Brainstorm.
https://neuroimage.usc.edu/brainstorm/Tutorials/Scripting

Hello,

I was recently working on a similar problem. The following code might help you:
d(i,j) contains the distance between vertex i and j (in a number of vertex between i and j). For your case, you might want to know also the length of the vertex, also you might want to make sure that all vertex have the same length

SubjectName = 'Subject03';
sSubject = bst_get('Subject',SubjectName);

sCortex = in_tess_bst(sSubject.Surface(sSubject.iCortex).FileName);
VertConn = sCortex.VertConn;

G = graph(VertConn);
d = distances(G);

Vertices1 =sCortex.Atlas(strcmp({sCortex.Atlas.Name},'Yeo 7 Networks')).Scouts(8).Vertices;
Vertices2 =sCortex.Atlas(strcmp({sCortex.Atlas.Name},'Yeo 7 Networks')).Scouts(6).Vertices;

figure;
imagesc(d(Vertices1,Vertices2)) % plot the distance between scout 8 and 6

The following page might help:

These functions consider only the graph of connectivity between vertices within the mesh.
The size of the triangles in the surfaces generated with reducepatch (such as your cortex_15000V surface) are very variable. If you want a length in Euclidean distances, you'd need to compute the size of each edge on the path.

Then you'd have to decide whether the distance between two scouts represents the distance between the central vertex of the patch, or the minimal distance between the closest vertices.

1 Like