8000 Remove SPMpath.mat - osp_Toolbox_Check - Helge Zöllner by HJZollner · Pull Request #423 · schorschinho/osprey · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Remove SPMpath.mat - osp_Toolbox_Check - Helge Zöllner #423

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 8, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 2 additions & 18 deletions GUI/osp_Toolbox_Check.m
Original file line number Diff line number Diff line change
Expand Up @@ -57,24 +57,8 @@
allFolders = strsplit(settingsFolder, filesep);
ospFolder = strjoin(allFolders(1:end-1), filesep); % parent folder (= Osprey folder)

% SPM
if isfile(fullfile(ospFolder,'GUI','SPMpath.mat')) % Load path to SPM
load(fullfile(ospFolder,'GUI','SPMpath.mat'),'SPMpath')
if exist(SPMpath, 'dir')
spmversion = SPMpath;
else %This isn't the right SPM path (maybe it was copied from another machine)
spmversion = uipickfiles('FilterSpec',ospFolder,'REFilter', '\','NumFiles',1,'Prompt','Select your SPM-folder (Will be saved in SPMpath.mat file in the GUI folder)');
spmversion = spmversion{1};
SPMpath = spmversion;
save(fullfile(ospFolder,'GUI','SPMpath.mat'),'SPMpath');
end
else %Set path to SPM
spmversion = uipickfiles('FilterSpec',ospFolder,'REFilter', '\','NumFiles',1,'Prompt','Select your SPM-folder (Will be saved in SPMpath.mat file in the GUI folder)');
spmversion = spmversion{1};
SPMpath = spmversion;
save(fullfile(ospFolder,'GUI','SPMpath.mat'),'SPMpath');
end
% Check if SPM12 is installed
% Get SPM folder and check if SPM12 is installed
spmversion = fileparts(which(fullfile('spm.m')));
if isempty(spmversion)
hasSPM = 0;
elseif strcmpi(spmversion(end-3:end),'spm8')
Expand Down
0