Hi, given the following code
n=length(x)f = zeros(1,n)for i = 1:nif x(i) == 1 f(1,i) = 22;elseif x(i)==2f(1,i) = 23;elseif x(i)==3f(1,i)= 21;elseif x(i)==4f(1,i) = 23;elseif x(i)==5f(1,i)= 24;endendC= char (f)
I don't know why but the 'char' conversion doesn't work giving to me the following
so with nothing inside the vector, that I need later for a switch case.
Do you know how to fix the problem?
Best Answer