From help-octave-request at bevo dot che dot wisc dot edu Sat Dec 12 09:49:31 1998 Subject: Re: simple question From: Frederick (Rick) A Niles To: Vitaliy A Repin cc: help-octave at bevo dot che dot wisc dot edu, niles@axp745.gsfc.nasa.gov Date: Sat, 12 Dec 98 10:53:34 -0500 > One simple question. > There is a matrix A: > > How can I use the first/second column or row of this matrix? > Is there any Octave operator which gives me the n-th column(row) > of matrix as vector? octave:1> A= [[1 2] > [3 4] > [5 6] > [7 8] > [9 10] > [0 2] > [3 4]] A = 1 2 3 4 5 6 7 8 9 10 0 2 3 4 octave:2> A(:,2) ans = 2 4 6 8 10 2 4 octave:3> A(2,:) ans = 3 4 octave:4> ----------------- Transpose with "'" (single quote) and you should probably RTFM. :) Rick Niles.