Skip to content
Snippets Groups Projects
Commit 50f33059 authored by Achilles Kappis's avatar Achilles Kappis
Browse files

Fix input argument checking to allow single monitoring microphone and source calculations

parent 0d87085a
No related branches found
No related tags found
1 merge request!3Update to v0.2.3
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
% Author: Achilles Kappis % Author: Achilles Kappis
% e-mail: axilleaz@protonmail.com % e-mail: axilleaz@protonmail.com
% %
% Date: 13/09/2024 (DD/MM/YYYY) % Date: 14/09/2024 (DD/MM/YYYY)
% %
% Copyright: MIT % Copyright: MIT
% -------------------------------------------------- % --------------------------------------------------
...@@ -73,8 +73,8 @@ function [estPerMic, est, err, estMean, errMean] = obsFiltEstTD(m, O, e) ...@@ -73,8 +73,8 @@ function [estPerMic, est, err, estMean, errMean] = obsFiltEstTD(m, O, e)
validateattributes(O, "numeric", {'real', 'nonnan', 'nonempty', 'finite'}, mfilename, "Observation filters", 2); validateattributes(O, "numeric", {'real', 'nonnan', 'nonempty', 'finite'}, mfilename, "Observation filters", 2);
% Check for observation filter size % Check for observation filter size
if ismatrix(O) || ndims(O) > 4 if ndims(O) > 4
error("Observation filter must be either a three- or four-dimensional array. See documentation (at the top of the function file) for more information."); error("Observation filter array cannot have more than four dimensions. See documentation (at the top of the function file) for more information.");
elseif size(O, 4) ~= size(m, 3) && size(O, 4) ~= 1 elseif size(O, 4) ~= size(m, 3) && size(O, 4) ~= 1
error("The number of observation filter sets must be either equal to the trials/sound field realisations, or 1.") error("The number of observation filter sets must be either equal to the trials/sound field realisations, or 1.")
end end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment