--- MITgcm_contrib/gmaze_pv/pv_checkpath.m 2006/06/16 21:28:39 1.2 +++ MITgcm_contrib/gmaze_pv/pv_checkpath.m 2007/09/19 14:45:59 1.4 @@ -1,5 +1,5 @@ % -% [] = PV_CHECKPATH() +% [] = pv_checkpath() % % This function detects where the package gmaze_pv is installed % (the upper level directory where the function volbet2iso @@ -15,13 +15,14 @@ % Determine the directory name where the package is installed: -w = which('volbet2iso'); -packdir = w(1:length(w)-12); +fct_to_find = 'pv_checkpath'; +w = which(fct_to_find); +packdir = w(1:length(w)-(length(fct_to_find)+2)); % Try to found needed subdirectories: -subdir = struct('name',{'subfct','test'}); +subdir = struct('name',{'subfct','test','visu','subduc'}); for id = 1 : size(subdir(:),1) subdirname = subdir(id).name;