[R] How to assigen column of matrix
tlumley at u.washington.edu
Mon Apr 21 17:25:50 CEST 2003
On Mon, 21 Apr 2003, Minghua Yao wrote:
> A simple question.
> I want to assign values to columns (or rows) of a matrix.
> It seems that
> AA[,i]<-A; # A is a vector or array;
> doesn't work.
It seems that it does work for me:
[1,] 1 3
[2,] 2 4
[1,] 1 10
[2,] 2 11
if that's what you were trying to do. Note that command lines in R don't
end with a ;, but in this case it doesn't matter.
More information about the R-help