function lUniqueProbes = findUniqueProbes(probeSites)
%

%   Copyright 2018 The MathWorks, Inc.
%   
%   Remove probes that start and end on the same line

alreadyDone = false(size(probeSites));
lUniqueProbes = true(size(probeSites));
for i=1:length(probeSites)-1
    if ~alreadyDone(i)
        idxSameFile  = [probeSites(:).FileNameIdx] == probeSites(i).FileNameIdx;
        idxSameStart = [probeSites(:).StartLineNo] == probeSites(i).StartLineNo;
        idxSameEnd   = [probeSites(:).EndLineNo] == probeSites(i).EndLineNo;
        duplicatedProbes = idxSameFile & idxSameStart & idxSameEnd;
        alreadyDone = alreadyDone | duplicatedProbes;
        duplicatedProbes(i) = false;
        lUniqueProbes = lUniqueProbes & ~duplicatedProbes;
    end
end

