error about graphvar

Submitted by yangth0306 on
Dear prof., 
There is an error shown below, could you help me? Thanks a lot.
Warning: Could not find an exact (case-sensitive) match for 'graphvar'.
F:\FDataanalysis\DATAanalysis\GraphVar_beta_v_05.1\GraphVar_beta_v_05.1\src\gui\GraphVar\GraphVar.m
is a case-insensitive match and will be used instead.
You can improve the performance of your code by using exact
name matches and we therefore recommend that you update your
usage accordingly. Alternatively, you can disable this warning using
warning('off','MATLAB:dispatcher:InexactCaseMatch').
This warning will become an error in future releases. 
??? Error: File: CalcVars.m Line: 122 Column: 17
The variable shuffelFiles in a parfor cannot be classified.
 See Parallel for Loops in MATLAB, "Overview".
 
Error in ==> GraphVar_calc at 85
[res,shuffelFiles] =
CalcVars(dialogData.thresholds,dialogData.thresholdType,dialogData.brainD,dialogData.functionList,handles.vpFiles,'TaskPlaner',allTasks,'MatrixName',dialogData.MatrixName,'FilePo
Error in ==> GraphVar>Btn_calcCorr_Callback at 71
[res allTask] = GraphVar_calc(handles);
 
Error in ==> gui_mainfcn at 96
        feval(varargin{:});
 
Error in ==> GraphVar at 40
    gui_mainfcn(gui_State, varargin{:});
 
Error in ==>
@(hObject,eventdata)GraphVar('Btn_calcCorr_Callback',hObject,eventdata,guidata(hObject))
 
 
??? Error while evaluating uicontrol Callback
 

Johann Kruschwitz

Mon, 04/13/2015 - 09:46

Hi,

please type:

start_GraphVar 

Also refer to the manual or the Starters_QuickGuide for further questions (there we describe in detail how to handle the toolbox)

All the best,
Johann

Johann Kruschwitz

Mon, 04/13/2015 - 10:01

Sorry - I didn´t realize that there were more errors hidden in the long description you posted.

The problem for me is that I don´t know what you did exactly and thus do not know in what kind of configuration this happes.
However, it seem that you have an old GraphVar version as the variable "ShuffelFiles" (sorry for the typo in the code!) is no longer Line 122.

Please download the new version (beta_0.6) - and/or (if you have the newest version) remove all old graphVar Versions from your Matlab path to prevent conflicts between old and new scripts.

Best,
Johann

yangth0306

Tue, 04/14/2015 - 14:20

In reply to by Johann Kruschwitz

Thank you for your reply.

I have tried the new version (beta_0.6) and set the parameters according the tutorial, however, i get an error shown below:

??? Error: File: CalcVars.m Line: 146 Column: 17

The variable shuffelFiles in a parfor cannot be classified.
 See Parallel for Loops in MATLAB, "Overview".
 
Error in ==> GraphVar_calc at 85
[res,shuffelFiles] =
CalcVars(dialogData.thresholds,dialogData.thresholdType,dialogData.brainD,dialogData.functionList,handles.vpFiles,'TaskPlaner',allTasks,'MatrixName',dialogData.MatrixName,'FilePo
Error in ==> GraphVar>Btn_calcCorr_Callback at 71
[res allTask] = GraphVar_calc(handles);
 
Error in ==> gui_mainfcn at 96
        feval(varargin{:});
 
Error in ==> GraphVar at 40
    gui_mainfcn(gui_State, varargin{:});
 
Error in ==>
@(hObject,eventdata)GraphVar('Btn_calcCorr_Callback',hObject,eventdata,guidata(hObject))
 
 
??? Error while evaluating uicontrol Callback
below is the setings. Thanks  a lot.
 

Hi,

I tried to replicate the error with the settings you posted but the error did not occur for me. I tried in two Matlab versions (2011 and 2014).

The error you report occurs in a parfor loop - which is odd as  you have selected "0" parallel Workes in the GUI (i.e., GraphVar should not run into this loop but instead use the loop starting from line 153). Probably you have the matlabpool activated before opening GraphVar (otherwise I would not know how this happens). Please make sure that the matlabpool is closed and try to run your settings again (if this works, there seems to be something wrong with your parallel computing settings)

Which Matlab version do you use? Do you have experienced problems with the parallel computing toolbox in other cases?
Please let me know if this works,
Johann

yangth0306

Wed, 04/15/2015 - 14:52

In reply to by Johann Kruschwitz

Dear Johann,

I used the version of 2009 matlab. There is no similar problem.

Now, i try again with another computer with the matlab version of 2012b. unfortunately, i meet another problem shown in below figure.

error: please select subject name in file name

but i indeed have selected the subject name by the mouse.

Hi,

please highlight the subject name again and check if the number in the "Start" field changes from 21 to 12 (as I see in your screenshot it is 21).  12 should be the starting character and  End 4. If for some reason it does not work properly when using the mouse you can alternatively enter the starting and end character manually.

Hope it works now!

Johann

Dear Johann,

I have manually enter the starting and end character, and it works. But at the end of calculation, an error occured as below:

Welcome to GraphVar
Release= beta 0.6
GraphVar was developed by David List*, Johann Kruschwitz*, and L. Waller and Mikael Rubinov; *equal contribution
Division of Mind and Brain Research, Department for Psychiatry, Charit? Berlin, Germany
Department for General Psychology, Technische Universit鋞 Dresden TUD, Germany
Brain Mapping Unit, Department of Psychiatry, University of Cambridge, Cambridge, United Kingdom
Funding for this project was provided by the German Research Foundation (DFG) grant SFB940/1 2014
Mail to Authors:  david.list@charite.de; johann.kruschwitz@charite.de
-----------------------------------------------------------
Citing Information:
If you think GraphVar is useful for your work, citing it in your paper would be greatly appreciated.
Reference: Kruschwitz JD, List D, Waller L, Rubinov M, Walter H, GraphVar: A user-friendly toolbox for comprehensive graph analyses of functional brain connectivity, Journal of Neuroscience Methods (2015), http://dx.doi.org/10.1016/j.jneumeth.2015.02.021
Warning: Possible deprecated use of set on a Java object with an HG Property 'MouseMovedCallback'. 
> In GraphVar>list_brainvars_var_Callback at 63
  In gui_mainfcn at 96
  In GraphVar at 40
  In @(hObject,eventdata)GraphVar('list_brainvars_var_Callback',hObject,eventdata,guidata(hObject)) 
Warning: Possible deprecated use of set on a Java object with an HG Property 'MouseMovedCallback'. 
> In GraphVar>list_brainvars_var_Callback at 63
  In gui_mainfcn at 96
  In GraphVar at 40
  In @(hObject,eventdata)GraphVar('list_brainvars_var_Callback',hObject,eventdata,guidata(hObject)) 
Starting matlabpool using the 'local' profile ... Warning: File: CalcVars.m Line: 140 Column: 54
The temporary variable randM will be cleared at the beginning of each iteration of the parfor loop.
Any value assigned to it before the loop will be lost.  If randM is used before it is assigned in
the parfor loop, a runtime error will occur.
See Parallel for Loops in MATLAB, "Temporary Variables". 
> In GraphVar_calc at 85
  In GraphVar>Btn_calcCorr_Callback at 71
  In gui_mainfcn at 96
  In GraphVar at 40
  In @(hObject,eventdata)GraphVar('Btn_calcCorr_Callback',hObject,eventdata,guidata(hObject))
  In distcomp.interactiveclient.pGetSockets>iGetSingleConnection at 60
  In distcomp.interactiveclient.pGetSockets at 16
  In distcomp.interactiveclient.start at 99
  In MatlabpoolHelper>MatlabpoolHelper.doOpen at 306
  In MatlabpoolHelper>MatlabpoolHelper.doMatlabpool at 137
  In matlabpool at 139
  In GraphVar>editParallelWorkersNumber_Callback at 743
  In gui_mainfcn at 96
  In GraphVar at 40
  In @(hObject,eventdata)GraphVar('editParallelWorkersNumber_Callback',hObject,eventdata,guidata(hObject)) 
stopped.
 
Error using matlabpool (line 144)
Failed to open matlabpool. (For information in addition to the causing error, validate the
profile 'local' in the Cluster Profile Manager.)
 
Error in GraphVar>editParallelWorkersNumber_Callback (line 743)
            matlabpool (Size_MatlabPool)
 
Error in gui_mainfcn (line 96)
        feval(varargin{:});
 
Error in GraphVar (line 40)
    gui_mainfcn(gui_State, varargin{:});
 
Error in
@(hObject,eventdata)GraphVar('editParallelWorkersNumber_Callback',hObject,eventdata,guidata(hObject))
 
 
Caused by:
    Error using distcomp.interactiveclient/pGetSockets>iThrowIfBadParallelJobStatus (line 101)
    The interactive communicating job errored with the following message:
    LocalClosedPossibleTimeout: The local socket stopped communicating with the remote socket,
    most likely because the remote socket failed to respond before a timeout.
    The remote socket is null.
    The local socket is /127.0.0.1:57751.
 
Error while evaluating uicontrol Callback
In addition, could you tell me how to know "12 should be the starting character and  End 4"? 
Best wishes
Tianhua 

Hi, Something seems wrong with your parallel processing toolbox I belief. To solve this problem I would suggest that you try not to use the parallel processing capabilities. So please turn off your matlabpool before opening graphvar and please set the numberparallel workers to 0 in the general settings. I hope this will (at least temporally) solve your problem. you would know the starting and the end point in the file name as this is defined by the start and end of your subject name (in the sample workspace "sample_01". This is the same name as in the variables sheet. All the best, Johann

Dear Johann,

I am sorry to disturb you. When i do the the partial correlation of chilli eating contest with beer pong score as  stated in the tutorial, it works well. 

but, when i do the group comparison, an error occured, whenever i hit statistics with already calculated values or calculate and statistics butten; the parameters are the same as previous. The error is below:

Undefined function 'nanvar_base' for input arguments of type 'double'.
 
Error in nanvar (line 27)
    Y = nanvar_base(X, dim);
 
Error in ttest2 (line 134)
s2x = nanvar(x,[],dim);
 
Error in executeStats>StatsFunction (line 445)
                    [~,pVal(count)] =
                    ttest2(brainData(strcmpi(variable,uGroup(i))),brainData(strcmpi(variable,uGroup(ii))));
                    
Error in executeStats>nDimStats (line 316)
        Result =
        StatsFunction(fid,subjectList,brainData,variable,StatsType,partialVar,isRand,0);
 
Error in executeStats (line 97)
                            [res, Result] =
                            nDimStats(fid,subjectList,actTask,GraphVar.Result,VarData,statsType,[],i_run
                            > 1);
 
Error in GraphVar_corr (line 89)
    [Files,N] =
    executeStats(allTasks,dialogData.statsType,dialogData.functionList,dialogData.thresholds,dialogData.VarList,dialogData.CovarList,nRandom,dialogData.nShuffel,0,dialogData.ConnectivityT
    Error in GraphVar>Btn_calcCorr_Callback (line 73)
    GraphVar_corr(handles,allTask)
 
Error in gui_mainfcn (line 96)
        feval(varargin{:});
 
Error in GraphVar (line 40)
    gui_mainfcn(gui_State, varargin{:});
 
Error in
@(hObject,eventdata)GraphVar('Btn_calcCorr_Callback',hObject,eventdata,guidata(hObject))
 
 
Error while evaluating uicontrol Callback
 
Thanks again.

Dear Johann,

I used Dparsf to extract aal(90) roi time courses signals, and i get a file with 195X90 format. then i use graphvar  and hit the butten of creat connectivity matrix, then hit generate conn matrix(default:peason) butten, however, graphvar can not recognize the file. i compare the file with the sample data in garphvar, the format of it is different(195x90 compared with 150X216). could you help solve the problem? thanks a lot.

attached is the file in matlab

best wishes

Hi, the reason that your format is 90x195 is that you have 195 scans (i.e. volumes) for your data. This is not a problem. If you push the button "generate conn matrix" graphvar should open a file selection prompt. Here you will have to select ALL the 90x195 .mat files for the subjects (i.e. Dparsf gives you multiple files - one 90x195 per subject). If you do that it will work (for graphvar you always have to select at minimum two files for generating conn matrices).  Next: the brain regions file can stay like it is in graphvar (but if you only have 90 regions do not select the cerebellar areas, which are not selected by default ... this would be 116 regiins instead). Subsequently load your personal variables sheet. Best, Johann

Dear Johann,

 When i do the the network based statistics to  identify a graph component that relates to age, hit the "show network" button as  stated in the tutorial, an error occured; in additon, the button including two( getcomponent and NBS) is different with the button( show network) in the tutorial.  

could you help me? The error is below:

Error using zeros
Size inputs must be scalar.
 
Error in Results_btn_network_Callback>loadAndProcessData (line 410)
    maxFreq = zeros(1,matrix_size);
 
Error in Results_btn_network_Callback (line 56)
    handles.networkData = loadAndProcessData(hObject, handles,corAlpha,1);
 
Error in gui_mainfcn (line 95)
        feval(varargin{:});
 
Error in Results (line 34)
    gui_mainfcn(gui_State, varargin{:});
 
Error in @(hObject,eventdata)Results('Results_btn_network_Callback',hObject,eventdata,guidata(hObject),1)
 
 
Error while evaluating UIControl Callback
 
Thanks again.

Johann Kruschwitz

Fri, 05/22/2015 - 13:30

Hi,

thanks for this question! This seems to be a bug in newer MATLAB versions. To solve this error please open the script "Results_btn_network_Callback" in GraphVar_beta_v_06\src\gui\Results and change the statement in line 369 "matrix_size = size(data)" to "matrix_size = length(data)". 

Please have a look in the "Dynamic GraphVar tutorial" -> on the last slides it is explained what the difference between "Get Component" and "NBS" is (NBS is equivalent to the old button "Show Network").

 

Hope this helps,

Johann

Dear Johann,

Thank you for your reply. and it works now according to your suggestion. however another problem appeared.

When i hit the button of NBS, no error reported, but also no results were produced shown in the attached image.

and if i press the button of brainne or export or export p, an error appeared. it is shown below:

Error using  == 
Matrix dimensions must agree.
 
Error in Results_btn_network_Callback>openBrainNet (line 203)
    brainIdx = find(handles.networkData.or1 == drawArg2(selectedNetworkID));
 
Error while evaluating UIControl Callback
Best wishes

Johann Kruschwitz

Wed, 05/27/2015 - 09:40

Hi,

in case you have installed SPM (added to your matlab path) can you please try to move SPM (including subfolders) to the bottom of your path? There are some functions in SPM that may interfer with some other matlab functions that GraphVar makes use of (you will also have to click on the graph component in the table to the right).

Best,
Johann 

yangth0306

Wed, 05/27/2015 - 14:08

In reply to by Johann Kruschwitz

Dear Johann,

I have moved SPM (including subfolders) to the bottom of my matlab path, the button of  export or export p works now; however, the button of brainne still did not work, and an error appeared as shown  before. In additon, i can not understand what the sentence (you will also have to click on the graph component in the table to the right) you have written mean. I am very sorry to disturb you for many times.

Error using  == 

Matrix dimensions must agree.
 
Error in Results_btn_network_Callback>openBrainNet (line 203)
    brainIdx = find(handles.networkData.or1 == drawArg2(selectedNetworkID));
 
Error while evaluating UIControl Callback
best wishes

Dear Johann,
Hi
I am trying to analysis my data including 35 subjects. I’ve used mutual information for creating my graphs, but I have serious problems. I attached my sample settings. Here is the error .I was wondering if you could help me.
Regards
 
Index exceeds matrix dimensions.
 
Error in executeStats (line 83)
                            if isnumeric(VarData{1})
 
Error in GraphVar_corr (line 89)
    [Files,N] =
    executeStats(allTasks,dialogData.statsType,dialogData.functionList,dialogData.thresholds,dialogData.VarList,dialogData.CovarList,nRandom,dialogData.nShuffel,0,dialogData.ConnectivityT
    Error in GraphVar>Btn_calcCorr_Callback (line 73)
    GraphVar_corr(handles,allTask)
 
Error in gui_mainfcn (line 96)
        feval(varargin{:});
 
Error in GraphVar (line 40)
    gui_mainfcn(gui_State, varargin{:});
 
Error in
@(hObject,eventdata)GraphVar('Btn_calcCorr_Callback',hObject,eventdata,guidata(hObject))
 
 
Error while evaluating uicontrol Callback
 
Meysam Siyah Mansoory
PhD Student in Biomedical Engineering

Tehran University of Medical Science


From: The R-fMRI Network <rfmri.org@gmail.com>
To: rfmri.org@rnet.co
Sent: Wednesday, May 27, 2015 6:38 PM
Subject: Re: [RFMRI] error about graphvar

Forums