function ypred = algoChoose(Xtrain, ytrain, Xtest, alpha, gamma)

if(~exist('alpha','var'))
    alpha = 0.004;
end

if(~exist('gamma','var'))
    gamma = 0;
end

[ypredDmitry weightsDmitry] = algoDmitry(Xtrain,ytrain,Xtest);
[ypredOstapec weightsOstapec] = algoStapec(Xtrain,ytrain,Xtest);

ypred = ypredOstapec;
iDmitryIsBetter = abs(weightsDmitry)>(alpha*abs(weightsOstapec)+gamma);
ypred(iDmitryIsBetter) = ypredDmitry(iDmitryIsBetter);

iz = ~any(ypred,2);
ypred(iz,:) = ypredOstapec(iz,:);

fprintf('%d changed, ',sum(sum(iDmitryIsBetter)));

%fprintf('%.4f %.4f ',C,B);

end