I have the following code.
I would like it to work such that if the first element of Ox is greater than zero, which in this case it is, the 1st, 5th, 9th, 13th, 17th, 21st, 25th, etc up to the end of Array will be multiplied by the first element of Ox.
So the output would be:
AllOx1 = (0.5 1 1 1 0.5 1 1 1 0.5 1… etc)
Ox = [0.5 0 0 0];Array = ones(1,256); AllOx1 = [];if Ox(1) > 0 AllOx1 = (Array(1:4:end)*Ru(1), 1, []);end
Any help would be much appreciated!
Thank you
Best Answer