hi. im new in MATLAB.
i think its a simple question.
i want:
a=1.154648126486416
to become
a=1.154
and not
a=1.54000000000
how do i do that without useing format('bank').
thanks.
I need to random some elements from an array. I'm doing that by randomizing the index $array[int(rand(100))]. I want some of the elements to appear more often. How do I do it?
I thought of a stupid solution of having those elements duplicated several times in the array, but I'm sure you guys can do better.