|
From: | Ben Abbott |
Subject: | Re: Cumulant vector |
Date: | Mon, 22 Oct 2007 08:48:54 -0400 |
On Oct 22, 2007, at 8:07 AM, Oscar Bayona Candel wrote:
Hi all,There is some function or easy way in Octave that permit you acumulate reference points?I mena, for example, a=[1 2 3 4 5] b=[1 3 6 10 15] b sums the previous sum of the matrix. so that b is the results of doing these kind of operations: b[1,1)=a(1,1) b(1.2)=b(1.1)+a(1.2)....b(1.5)=b(1.4)+b(1.5) Thanks in advance.
Not sure what you mean by "accumulate reference points" ... but is this the sort of thing you're looking for?
b = cumsum ([ 0, a ]); or b = [ a(1), cumsum (a) ];
[Prev in Thread] | Current Thread | [Next in Thread] |