help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: movavg is different using loop and matrix


From: Dmitri A. Sergatskov
Subject: Re: movavg is different using loop and matrix
Date: Thu, 5 Sep 2019 17:33:12 -0500

On Thu, Sep 5, 2019 at 4:35 PM gigiolone123 via Help list for GNU
Octave <address@hidden> wrote:
>
> hi, look this esample:
>
> DevPeriod=16;
> Equity=magic(100);
>
>    for hh=1:columns(Equity)
>       ma1=movavg(Equity(:,hh),DevPeriod,DevPeriod,0);
>   endfor
>
>  ma2=movavg(Equity,DevPeriod,DevPeriod,0);
>
>
> ma1 and ma2 are different from each other
>

ma1 is a vector (100x1) and ma2 is a matrix (100x100)

Dmitri.
--



reply via email to

[Prev in Thread] Current Thread [Next in Thread]