Mercurial > octave
changeset 28488:4304bf2b450b
maint: merge stable to default.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 18 Jun 2020 13:26:34 -0400 |
parents | 3a05402adef6 (current diff) a7fcdac012d8 (diff) |
children | aabfd3f51d0b |
files | |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/doc/interpreter/vectorize.txi Tue Jun 16 17:04:58 2020 -0400 +++ b/doc/interpreter/vectorize.txi Thu Jun 18 13:26:34 2020 -0400 @@ -693,9 +693,9 @@ @example @group -n = length (A); +n = length (A) - 1; B = zeros (n, 2); -for i = 1:length (A) +for i = 1:n ## this will be two columns, the first is the difference and ## the second the mean of the two elements used for the diff. B(i,:) = [A(i+1)-A(i), (A(i+1) + A(i))/2];