function [B,I] = rmmissing(A,varargin)
%RMMISSING Remove rows or columns with missing entries
%   
%   B = RMMISSING(A)
%   B = RMMISSING(A,DIM)
%   B = RMMISSING(A,...,'MinNumMissing',N)
%   [B,I] = RMMISSING(A,...)
%   
%   See also: RMMISSING, CODISTRIBUTED.
%   


%   Copyright 2019 The MathWorks, Inc.

% Only A is allowed to be remote.
if nargin>1
    [varargin{:}] = gather(varargin{:});
end
% If A is not remote this will run replicated.
if nargout>1
    [B, I] = matlab.internal.math.rmMissingOutliers('rmmissing',A,varargin{:});
else
    B = matlab.internal.math.rmMissingOutliers('rmmissing',A,varargin{:});
end
