[Rd] How x[, 'colname1'] is implemented?

Peng Yu pengyu.ut at gmail.com
Fri Jan 1 00:27:50 CET 2010


I don't see where describes the implementation of '[]'.

For example, if x is a matrix or a data.frame, how the lookup of
'colname1' is x[, 'colname1'] executed. Does R perform a lookup in the
a hash of the colnames? Is the reference O(1) or O(n), where n is the
second dim of x?



More information about the R-devel mailing list