Bump minimal required version of Octave to 7.1.0
Incidentally, this means that the JSONlab submodule is no longer needed, so it is removed in the present commit. Closes: #1907dcontrib-log
parent
d55b6c68f9
commit
1d5a442fe5
|
@ -14,9 +14,6 @@
|
|||
path = matlab/modules/dseries
|
||||
url = ../../Dynare/dseries.git
|
||||
branch = master
|
||||
[submodule "contrib/jsonlab"]
|
||||
path = contrib/jsonlab
|
||||
url = https://github.com/fangq/jsonlab.git
|
||||
[submodule "preprocessor"]
|
||||
path = preprocessor
|
||||
url = ../../Dynare/preprocessor.git
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
Subproject commit 5a58fafdca239e61be4d7b2270307b2445bb571a
|
|
@ -15,7 +15,7 @@ compilation steps are necessary in that case.
|
|||
In order to run Dynare, you need one of the following:
|
||||
|
||||
* MATLAB, any version ranging from 9.5 (R2018b) to 23.2 (R2023b);
|
||||
* GNU Octave, any version ranging from 6.2.0 to 8.4.0, with the statistics package
|
||||
* GNU Octave, any version ranging from 7.1.0 to 8.4.0, with the statistics package
|
||||
from `Octave-Forge`_. Note however that the Dynare installer for Windows
|
||||
requires a more specific version of Octave, as indicated on the download
|
||||
page.
|
||||
|
|
|
@ -145,7 +145,6 @@ fi
|
|||
|
||||
cp -p "$ROOTDIR"/scripts/dynare.el "$PKGFILES"/scripts
|
||||
cp -pr "$ROOTDIR"/contrib/ms-sbvar/TZcode/MatlabFiles "$PKGFILES"/contrib/ms-sbvar/TZcode
|
||||
cp -pr "$ROOTDIR"/contrib/jsonlab "$PKGFILES"/contrib
|
||||
|
||||
cp "$ROOTDIR"/build-doc/*.pdf "$PKGFILES"/doc
|
||||
cp "$ROOTDIR"/build-doc/preprocessor/doc/*.pdf "$PKGFILES"/doc
|
||||
|
|
|
@ -28,7 +28,7 @@ function nls(eqname, params, data, range, optimizer, varargin)
|
|||
% equation must have NaN values in the object.
|
||||
% [4] It is assumed that the residual is additive.
|
||||
|
||||
% Copyright © 2021-2022 Dynare Team
|
||||
% Copyright © 2021-2023 Dynare Team
|
||||
%
|
||||
% This file is part of Dynare.
|
||||
%
|
||||
|
@ -179,12 +179,6 @@ write_residuals_routine(lhs, rhs, eqname, ipnames_, M_);
|
|||
% Create a routine for evaluating the sum of squared residuals of the nonlinear model
|
||||
write_ssr_routine(lhs, rhs, eqname, ipnames_, M_);
|
||||
|
||||
% Workaround for Octave bug https://savannah.gnu.org/bugs/?46282
|
||||
% Octave will randomly fail to read the ssr_* file generated in the +folder
|
||||
if isoctave && octave_ver_less_than('7')
|
||||
path(path)
|
||||
end
|
||||
|
||||
% Create a function handle returning the sum of square residuals for a given vector of parameters.
|
||||
ssrfun = @(p) feval([M_.fname '.ssr_' eqname], p, DATA, M_, oo_);
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ function nls(eqname, params, data, range, optimizer, varargin)
|
|||
% is available only if the matylab optimization toolbox is installed), the
|
||||
% remaining inputs are the options (key/value) passed to the optimizers.
|
||||
|
||||
% Copyright © 2018-2022 Dynare Team
|
||||
% Copyright © 2018-2023 Dynare Team
|
||||
%
|
||||
% This file is part of Dynare.
|
||||
%
|
||||
|
@ -96,12 +96,6 @@ write_residuals_routine(lhs, rhs, eqname, ipnames_, M_, pacmodl);
|
|||
% Create a routine for evaluating the sum of squared residuals of the nonlinear model
|
||||
write_ssr_routine(lhs, rhs, eqname, ipnames_, M_, pacmodl);
|
||||
|
||||
% Workaround for Octave bug https://savannah.gnu.org/bugs/?46282
|
||||
% Octave will randomly fail to read the ssr_* file generated in the +folder
|
||||
if isoctave && octave_ver_less_than('7')
|
||||
path(path)
|
||||
end
|
||||
|
||||
% Copy (sub)sample data in a matrix.
|
||||
DATA = data([range(1)-1, range]).data;
|
||||
|
||||
|
|
|
@ -81,9 +81,9 @@ if isoctave
|
|||
'of precompiled mex files and some\nfeatures, like solution ' ...
|
||||
'of models approximated at third order, will not be available.'], supported_octave_version())
|
||||
skipline()
|
||||
elseif octave_ver_less_than('6.2.0') % Should match the test in meson.build, and also the one in matlab/modules/dseries/src/initialize_dseries_class.m
|
||||
elseif octave_ver_less_than('7.1.0') % Should match the test in meson.build, and also the one in matlab/modules/dseries/src/initialize_dseries_class.m
|
||||
skipline()
|
||||
warning(['This version of Dynare has only been tested on Octave 6.2.0 and above. Dynare may fail to run or give unexpected result. Consider upgrading your version of Octave.'])
|
||||
warning(['This version of Dynare has only been tested on Octave 7.1.0 and above. Dynare may fail to run or give unexpected result. Consider upgrading your version of Octave.'])
|
||||
skipline()
|
||||
end
|
||||
else
|
||||
|
|
|
@ -34,11 +34,6 @@ global M_ options_ oo_ estim_params_ bayestopt_ dataset_ dataset_info
|
|||
dispString = 'Estimation::mcmc';
|
||||
|
||||
if ~exist([M_.dname filesep 'Output'],'dir')
|
||||
if isoctave && octave_ver_less_than('7') && ~exist(M_.dname)
|
||||
% See https://savannah.gnu.org/bugs/index.php?61166
|
||||
% This workaround is needed for recursive estimation.
|
||||
mkdir(M_.dname)
|
||||
end
|
||||
mkdir(M_.dname,'Output');
|
||||
end
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
function o = loadjson_(jsonfilename)
|
||||
|
||||
% Reads a json file using jsonlab toolbox or jsondecode builtin if available.
|
||||
% Reads a json file using jsondecode builtin.
|
||||
%
|
||||
% INPUTS
|
||||
% - jsonfilename [char] 1×n char array, name of the JSON file.
|
||||
|
@ -28,11 +28,6 @@ function o = loadjson_(jsonfilename)
|
|||
% You should have received a copy of the GNU General Public License
|
||||
% along with Dynare. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
if isoctave && octave_ver_less_than('7')
|
||||
o = loadjson(jsonfilename);
|
||||
return
|
||||
end
|
||||
|
||||
json = fileread(jsonfilename);
|
||||
|
||||
o = jsondecode(json); clear('json');
|
||||
|
|
|
@ -39,10 +39,6 @@ if nargin > 5 || nargin < 2 || nargout > 7 || nargout == 0
|
|||
error('MJDGGES: takes 2, 3 or 4 input arguments and between 1 and 7 output arguments.')
|
||||
end
|
||||
|
||||
if isoctave && octave_ver_less_than('7')
|
||||
error('Octave version 7 or higher is required (Octave 6 lacks the ordqz function)')
|
||||
end
|
||||
|
||||
[me, ne] = size(e);
|
||||
[md, nd] = size(d);
|
||||
if ~isreal(e) || ~isreal(d) || me ~= ne || md ~= nd || me ~= nd
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 99b6f167e71945a45249dbc6b5100d2ca6b1474f
|
||||
Subproject commit 80446e7cdcf392167e91b428b61d77e028e47674
|
|
@ -27,7 +27,7 @@ function varargout = pooled_ols(ds, param_common, param_regex, overlapping_dates
|
|||
% SPECIAL REQUIREMENTS
|
||||
% dynare must have been run with the option: json=compute
|
||||
|
||||
% Copyright © 2017-2019 Dynare Team
|
||||
% Copyright © 2017-2023 Dynare Team
|
||||
%
|
||||
% This file is part of Dynare.
|
||||
%
|
||||
|
@ -76,10 +76,6 @@ else
|
|||
end
|
||||
|
||||
st = dbstack(1);
|
||||
if isoctave && octave_ver_less_than('6.3.0')
|
||||
% Workaround for https://savannah.gnu.org/bugs/?60531, fixed in 6.3.0
|
||||
st = st(2:end);
|
||||
end
|
||||
if ~isempty(st) && strcmp(st(1).name, 'pooled_fgls')
|
||||
save_structure_name = 'pooled_fgls';
|
||||
else
|
||||
|
|
|
@ -18,7 +18,7 @@ function varargout = sur(ds, param_names, eqtags, model_name, noniterative, ds_r
|
|||
% SPECIAL REQUIREMENTS
|
||||
% dynare must have been run with the option: json=compute
|
||||
|
||||
% Copyright © 2017-2021 Dynare Team
|
||||
% Copyright © 2017-2023 Dynare Team
|
||||
%
|
||||
% This file is part of Dynare.
|
||||
%
|
||||
|
@ -121,10 +121,6 @@ end
|
|||
%
|
||||
|
||||
st = dbstack(1);
|
||||
if isoctave && octave_ver_less_than('6.3.0')
|
||||
% Workaround for https://savannah.gnu.org/bugs/?60531, fixed in 6.3.0
|
||||
st = st(2:end);
|
||||
end
|
||||
if ~isempty(st) && strcmp(st(1).name, 'surgibbs')
|
||||
varargout{1} = nobs;
|
||||
varargout{2} = X{param_names{:}}.data;
|
||||
|
|
|
@ -163,7 +163,7 @@ if get_option('build_for') == 'matlab'
|
|||
else # Octave build
|
||||
octave_exe = find_program('octave', required : not meson.is_cross_build(), disabler : true)
|
||||
mkoctfile_exe = find_program('mkoctfile')
|
||||
octave_minimal_version = '6.2.0'
|
||||
octave_minimal_version = '7.1.0'
|
||||
octave_version = run_command(mkoctfile_exe, '-v', check : true).stdout().replace('mkoctfile, version ', '').strip()
|
||||
|
||||
if octave_version.version_compare('<' + octave_minimal_version)
|
||||
|
|
|
@ -36,13 +36,7 @@ if isoctave
|
|||
mlist = mlist(find(~strcmp([matlab_dir filesep 'load_m_file_data_legacy.m'], mlist)));
|
||||
end
|
||||
|
||||
% Set random seed, for reproducibility
|
||||
if isoctave && octave_ver_less_than('7')
|
||||
randn('state',1);
|
||||
rand('state',1);
|
||||
else
|
||||
rng(1);
|
||||
end
|
||||
rng(1);
|
||||
|
||||
failedtests = {};
|
||||
|
||||
|
|
|
@ -119,8 +119,6 @@ cp -p windows/README.txt "$ZIPDIR"
|
|||
cp -pr windows/deps/mingw64 "$ZIPDIR"
|
||||
mkdir -p "$ZIPDIR"/contrib/ms-sbvar/TZcode
|
||||
cp -pr contrib/ms-sbvar/TZcode/MatlabFiles "$ZIPDIR"/contrib/ms-sbvar/TZcode
|
||||
mkdir -p "$ZIPDIR"/contrib/jsonlab
|
||||
cp -pr contrib/jsonlab/* "$ZIPDIR"/contrib/jsonlab
|
||||
mkdir -p "$ZIPDIR"/mex/matlab/win64-9.5-23.2
|
||||
cp -p build-win-matlab/*.mexw64 "$ZIPDIR"/mex/matlab/win64-9.5-23.2
|
||||
mkdir -p "$ZIPDIR"/mex/octave/win64
|
||||
|
|
Loading…
Reference in New Issue