diff --git a/matlab/+mom/run.m b/matlab/+mom/run.m index 1a57a9be47f8f036e7154643d511c111d9617dd9..3f750906e2fc4c75a7166b5593d45b48dec22176 100644 --- a/matlab/+mom/run.m +++ b/matlab/+mom/run.m @@ -590,7 +590,7 @@ fprintf('\n==== Method of Moments Estimation (%s) Completed ====\n\n',options_mo %reset warning state warning_config; -if isoctave && isfield(options_, 'prior_restrictions') && ... +if isoctave && isfield(options_mom_, 'prior_restrictions') && ... isfield(options_mom_.prior_restrictions, 'routine') % Octave crashes if it tries to save function handles (to the _results.mat file) % See https://savannah.gnu.org/bugs/?43215