From help-octave-request at bevo dot che dot wisc dot edu Fri Dec 19 04:51:22 2003 Subject: Re: "end" for row vectors From: Gerald Ebberink To: taltman at lbl dot gov Cc: Ricardo Cervera , help-octave@bevo.che.wisc.edu Date: Fri, 19 Dec 2003 11:50:28 +0100 -----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 taltman at lbl dot gov 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 > ebberi >To: Ricardo Cervera > ebberi >Cc: help-octave at bevo dot che dot wisc dot edu > ebberi >Subject: Re: "end" for row vectors > ebberi >Resent-Date: Thu, 18 Dec 2003 14:57:26 -0600 > ebberi >Resent-From: help-octave at bevo dot che dot wisc dot edu > 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 -------------------------------------------------------------