function [ outMat ] = mapVec2Mat( inVec )
% map vector to matrix
n = length(inVec);
p = length(unique(inVec));
outMat = zeros(n, p);
for i = 1: length(inVec)
    tmp = inVec(i);
    outMat(i, tmp) = 1;
end

end

