Hi, I am trying to write a method for [,data.frame,expression. But it give the error: * * *Error in xj[i] : invalid subscript type 'expression'*
I looked at the help files and the archives. No avail. Any ideas? Here is an example that reproduces the error. > setGeneric( '[' ) [1] "[" > setMethod( '[', c( 'data.frame', 'expression', 'ANY', 'ANY' ), + function(x, i, j, ..., drop ) { 1 } + ) [1] "[" > iris[ expression(1), ] Error in xj[i] : invalid subscript type 'expression' This is running R-2.11.1 on Windows and Linux. Thanks in Advance, Chris Open Data http://www.opendatagroup.com http://opendatagroup.com/category/blog [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.