Warning: Table './restf1_drupal/cache_page' is marked as crashed and should be repaired query: SELECT data, created, headers, expire, serialized FROM cache_page WHERE cid = 'http://restfmri.net/forum/node/1060' in /home/restf1/public_html/forum/includes/database.mysql.inc on line 136

Warning: Cannot modify header information - headers already sent by (output started at /home/restf1/public_html/forum/includes/database.mysql.inc:136) in /home/restf1/public_html/forum/includes/bootstrap.inc on line 726

Warning: Cannot modify header information - headers already sent by (output started at /home/restf1/public_html/forum/includes/database.mysql.inc:136) in /home/restf1/public_html/forum/includes/bootstrap.inc on line 727

Warning: Cannot modify header information - headers already sent by (output started at /home/restf1/public_html/forum/includes/database.mysql.inc:136) in /home/restf1/public_html/forum/includes/bootstrap.inc on line 728

Warning: Cannot modify header information - headers already sent by (output started at /home/restf1/public_html/forum/includes/database.mysql.inc:136) in /home/restf1/public_html/forum/includes/bootstrap.inc on line 729
AAL TC 提取 | Forum of resting-state fMRI

AAL TC 提取

warning: Cannot modify header information - headers already sent by (output started at /home/restf1/public_html/forum/includes/database.mysql.inc:136) in /home/restf1/public_html/forum/includes/common.inc on line 148.

DPARSF 的AAL 提取还能做AAL 1-90
昨天我试着提取116个AAL

DPARSFRun.m 的提取AAL脑区的子程序所有“for iAAL=1:90”改为“for iAAL=1:116”
但是最后生成的 AALTC.mat 文件中。时间序列只有1-99

100以后的时间序列被加在1-15时间序列的后边

详细的 .mat文件见附件

多谢指教

AttachmentSize
10027467072_AALTC.zip188.66 KB

Re

 你还需要把

AreaName=['0',num2str(iAAL)];

AreaName=AreaName(end-1:end);

改成

AreaName=['00',num2str(iAAL)];

AreaName=AreaName(end-2:end);

这段代码我以后修改一下吧,直接存在一个矩阵里好了。

另外,也可以用REST->Utilities->Extract ROI Signals中的multiple labels选项来提取时间序列。

按照您的指示修改以后,还是报错

Error using save
No variable matched the pattern 'AAL\w\wTC'.

Error in DPARSF_run (line 1274)
        save([AutoDataProcessParameter.DataProcessDir,filesep,FunImgDir,'_AALTC',filesep,AutoDataProcessParameter.SubjectID{i},'_AALTC.mat'],'-regexp',
        'AAL\w\wTC');

Error in DPARSF>pushbuttonRun_Callback (line 976)
    [Error]=DPARSF_run(handles.Cfg);

Error in gui_mainfcn (line 96)
        feval(varargin{:});

Error in DPARSF (line 43)
    gui_mainfcn(gui_State, varargin{:});
 
Error while evaluating uicontrol Callback
***********************************************************
我自己修改过的DPARSF_run.m的提取116个AAL Time Course的代码附后,麻烦指教,多谢!

*******

%Extract AAL Time Cources (116 areas)
if (AutoDataProcessParameter.IsExtractAALTC==1)
    if (AutoDataProcessParameter.DataIsSmoothed==1)
        FunImgDir='FunImgNormalizedSmoothedDetrendedFilteredCovremoved';
    else
        FunImgDir='FunImgNormalizedDetrendedFilteredCovremoved';
    end
    cd([AutoDataProcessParameter.DataProcessDir,filesep,FunImgDir]);
    mkdir([AutoDataProcessParameter.DataProcessDir,filesep,FunImgDir,'_AALTC',filesep])
    [AALData, Vox, Head] = rest_readfile([ProgramPath,filesep,'Templates',filesep,'AAL_61x73x61_YCG.nii']);
    for iAAL=1:116
        AreaName=['00',num2str(iAAL)];
        AreaName=AreaName(end-2:end);
        eval(['AAL',AreaName,'Index=find(AALData==',num2str(iAAL),');']);
    end
    for i=1:AutoDataProcessParameter.SubjectNum
        cd(AutoDataProcessParameter.SubjectID{i});
        for iAAL=1:116
            AreaName=['00',num2str(iAAL)];
            AreaName=AreaName(end-2:end);
            eval(['AAL',AreaName,'TC=[];']);
        end
        DirImg=dir('*.img');
        for j=1:AutoDataProcessParameter.TimePoints
            %Filename=['0000000',num2str(j)];Filename=Filename(end-7:end);Filename=[Filename,'.img'];
            Filename=DirImg(j).name;
            [Data, Vox, Head] = rest_readfile(Filename);
            for iAAL=1:116
                AreaName=['00',num2str(iAAL)];
                AreaName=AreaName(end-2:end);
                eval(['Temp=mean(Data(AAL',AreaName,'Index));']);
                eval(['AAL',AreaName,'TC=[AAL',AreaName,'TC;Temp];']);
            end
        end
        cd('..');
        save([AutoDataProcessParameter.DataProcessDir,filesep,FunImgDir,'_AALTC',filesep,AutoDataProcessParameter.SubjectID{i},'_AALTC.mat'],'-regexp', 'AAL\w\wTC');
        fprintf(['Extract AAL Time Cources: ',AutoDataProcessParameter.SubjectID{i},' OK']);
    end
    fprintf('\n');
end

**********************************

Re

 我下一个版本改一下吧。
现在先用这个:http://www.restfmri.net/forum/node/1059

好的,谢谢您

好的,谢谢您

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.