[R] Attributing values to matrix according to names
Peter Dalgaard
p.dalgaard at biostat.ku.dk
Thu Oct 20 16:29:10 CEST 2005
"Schneider, Manuel" <Manuel.Schneider at eawag.ch> writes:
> > data["10014",1,1]<-count["10014"]
> works but
>
> > data["names(count)",1,1]<-count["names(count)"]
> Fails with Error: indexing outside limits.
Well, you don't have a row named "names(count)" now do you? Try
dropping the quotes.
--
O__ ---- Peter Dalgaard Øster Farimagsgade 5, Entr.B
c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
More information about the R-help
mailing list