[datatable-help] Syntax: ag["M",age]$age ?

Dieter Menne dieter.menne at menne-biomed.de
Fri Jan 20 12:49:25 CET 2012


When I want the vector of the males, I use the following:

ag =
data.table(gender=rep(c("M","F"),10),age=seq(10,20,length.out=20),key="gender")
ag["M",age]$age

Just for the elegance:  did I miss some method to get this without the
trailing $age?

Dieter

--
View this message in context: http://r.789695.n4.nabble.com/Syntax-ag-M-age-age-tp4313006p4313006.html
Sent from the datatable-help mailing list archive at Nabble.com.


More information about the datatable-help mailing list