function res = antPositive(tab) % antall positive verdier i parameteren res = 0; for i = 1:length(tab) if (tab(i) >= 0) res = res + 1; end end end