From 8eb3023069849617320bce881d4f9e03b3cbd31d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Adjemian=20=28Charybdis=29?= Date: Mon, 12 Dec 2016 14:06:27 +0100 Subject: [PATCH] Changed isint function. To make it consistent with the routine available in the dates toolbox. --- matlab/utilities/general/isint.m | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/matlab/utilities/general/isint.m b/matlab/utilities/general/isint.m index f6ed5a64e..01f403d5d 100644 --- a/matlab/utilities/general/isint.m +++ b/matlab/utilities/general/isint.m @@ -1,4 +1,4 @@ -function [b,c,d] = isint(a) +function [l,c,d] = isint(a) % This function tests if the input argument is an integer. % % INPUT @@ -33,7 +33,7 @@ function [b,c,d] = isint(a) % along with Dynare. If not, see . if ~isnumeric(a) - b = false; + l = false; if nargout>1 c = []; d = []; @@ -41,11 +41,9 @@ if ~isnumeric(a) return end -[m,n] = size(a); - -b = abs(fix(a)-a)<1e-15; +l = abs(fix(a)-a)<1e-15; if nargout>1 - c = find(b==1); - d = find(b==0); + c = find(l==true); + d = find(l==false); end \ No newline at end of file