[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: "end" for row vectors
From: |
Gerald Ebberink |
Subject: |
Re: "end" for row vectors |
Date: |
Fri, 19 Dec 2003 11:50:28 +0100 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031203 |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
Whoops
it should say:
v(size(v,2))
but the other things you write here essentialy do the same :)
kind regards,
Gerald
address@hidden wrote:
> Hi,
>
> I get the following in Octave 2.1.50:
>
> octave> v = [ 1 2 3 4 5 6 7 8 9 10]
> v =
> 1 2 3 4 5 6 7 8 9 10
> octave> v(size(v))
> ans =
> 1 10
> octave>
>
> I think the following two methods would get the desired result:
>
> octave> v
> v =
> 1 2 3 4 5 6 7 8 9 10
> octave> v(columns(v))
> ans = 10
> octave> v(length(v))
> ans = 10
> octave>
>
> Wait, I just tried v(end), and it worked as expected. What
> version/platform combo are you using, again? Try upgrading to 2.1.50;
> 2.1.35 is quite old.
>
> HTH,
>
> ~Tomer
>
>
>
>
> On Dec 18, 2003 at 9:57pm, Gerald Ebberink wrote:
>
> ebberi >Date: Thu, 18 Dec 2003 21:57:24 +0100
> ebberi >From: Gerald Ebberink <address@hidden>
> ebberi >To: Ricardo Cervera <address@hidden>
> ebberi >Cc: address@hidden
> ebberi >Subject: Re: "end" for row vectors
> ebberi >Resent-Date: Thu, 18 Dec 2003 14:57:26 -0600
> ebberi >Resent-From: address@hidden
> ebberi >
> ebberi >
> ebberi >
> ebberi >
> ebberi >-------------------------------------------------------------
> ebberi >Octave is freely available under the terms of the GNU GPL.
> ebberi >
> ebberi >Octave's home on the web: http://www.octave.org
> ebberi >How to fund new projects: http://www.octave.org/funding.html
> ebberi >Subscription information: http://www.octave.org/archive.html
> ebberi >-------------------------------------------------------------
> ebberi >
> ebberi >
>
>
>
> -------------------------------------------------------------
> Octave is freely available under the terms of the GNU GPL.
>
> Octave's home on the web: http://www.octave.org
> How to fund new projects: http://www.octave.org/funding.html
> Subscription information: http://www.octave.org/archive.html
> -------------------------------------------------------------
>
- --
Ing. Gerald Ebberink
Laser Technician
Kernfysisch Versneller Instituut
Rijksuniversiteit Groningen
Zernikelaan 25
9747 AA Groningen
The Netherlands
tel: +31 50 363 3518
lab: +31 50 363 3588
fax: +31 50 363 4003
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQE/4tf8bSbfYz8yWIMRArWTAKCcZAbRHk+BF9EusEs2Z6Z7GTFbEQCg94NT
zKThC2YQOEHvMnXmqSXyk0o=
=WV1p
-----END PGP SIGNATURE-----
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------