Currently in matlab i have int array a=[8 3 2 1]; i want to convert it to binary array with four bits each.
for the above int array i would get the following binary array a binary=[1000 0011 0010 0001];
I tried the code given below:
binary = dec2bin([8 3 2 1],4)
I got answer as :
1000
0011
0010
0001
It is a column matrix.
But I need a row matrix. [1000 0011 0010 0001]
can anyone help me????
thanks in advance.