[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Vectorization
From: |
Thomas D. Dean |
Subject: |
Re: Vectorization |
Date: |
Tue, 07 Oct 2014 21:35:52 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.1.1 |
On 10/07/14 21:12, Thomas D. Dean wrote:
Sorry, I have been looking at this too long. I can iterate:
pvals=[0:20:240 255 240: -20:-240 -255 -240:20:0];
L=zeros(size(pvals));
R=L;
idx=0;
for p = pvals
L(++idx) = mean(encoder(pwm == p));
end
> size(Lpwm)
20571 1
> size(encoder)
20571 1
Tom Dean