Graph theory measures - Brain connectivity toolbox

Dear Sirs,
I am trying to extract graph theory measures using the brain connectivity toolbox (BCT).
I have created the connectivity matrices in ExploreDTI (see image attached with the output of the weighted and binary matrices).
Then I added the files with the CMs and the BCT to Matlab (by going into set path and add folder and save - see attached)
I then used the command window to type the functions in order to get the graph theory measures but I end up getting an error (see below an example where I try to extract efficiency measure from a binary CM):
>> efficiency_bin.m ('06_DWI_FP_MD_C_trafo_Tracts_CSD_binary_PASS')
Unable to resolve the name efficiency_bin.m.
I get the error message “Unable to resolve the name efficiency_bin.m” and I am now stuck.
Can anyone provide input on what can be the reason for this error?
Thank you.
Best wishes,
Jose Teles

1 commentaire

原
le 28 Juin 2022
excuse me,could you tell me how to start BCT in Matlab?The code I press into mtalab always shows error,brain connectivvty?or sth else?thanks a lot!

Connectez-vous pour commenter.

 Réponse acceptée

efficiency_bin('06_DWI_FP_MD_C_trafo_Tracts_CSD_binary_PASS')
Do not include the ".m" part of the name when invoking a function.

7 commentaires

Dear Walter Robertson,
Thank you for the reply your suggestion eliminated the error. If perhaps you could help with another question/error message that I have encounter while trying to run a graph measure of global efficiency on my weighted CM as listed below:
>> rout_efficiency ('06_DWI_FP_MD_C_trafo_Tracts_CSD_FA_PASS')
Index in position 1 exceeds array bounds. Index must not exceed 1.
Error in distance_wei_floyd (line 104)
i2k_k2j = bsxfun(@plus, SPL(:,k), SPL(k,:));
Error in rout_efficiency (line 74)
Erout = distance_wei_floyd(D,transform); % pair-wise routing efficiency"
What does Index in position 1 exceeds array bounds. Index must not exceed 1 means? How can I solve this issue?
Thank you
% Inputs:
%
% D,
% Weighted/unweighted directed/undirected
% connection *weight* OR *length* matrix.
%
But what you passed in is a character vector, not a connection matrix.
Thank you again. But I am a bit confused now because the ExploreDTI manual refers to these files created as connectivity matrices (CMs) (see attached a print of the manual referring to the very same files I have extracted as CMs)
I have also attached the .mat file perhaps this could help? Not sure how to move along
You have to load the .mat file and pull the variable CM out of it.
Hello again I think I am not following your suggestions correctly
I tried to copy the .mat to the BCT folder (my current directory) then loaded the .mat file and tried to get the global efficiency measure but still get the same error message (see below)
"
>> load ('06_DWI_FP_MD_C_trafo_Tracts_CSD_FA_PASS')
>> rout_efficiency ('06_DWI_FP_MD_C_trafo_Tracts_CSD_FA_PASS')
Index in position 1 exceeds array bounds. Index must not exceed 1.
Error in distance_wei_floyd (line 104)
i2k_k2j = bsxfun(@plus, SPL(:,k), SPL(k,:));
Error in rout_efficiency (line 74)
Erout = distance_wei_floyd(D,transform); % pair-wise routing efficiency
"
I think I am misinterpreting your feedback perhaps you could provide input on the steps? Sorry I really appreciate your patience is just that I am very new to matlab
load('06_DWI_FP_MD_C_trafo_Tracts_CSD_FA_PASS')
rout_efficiency(CM)
Many thanks for your advise it worked:) have a great day

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by