Every time I have to prefix a dataframe column inside the indexing brackets with the dataframe name, e.g.

df[df$colname==value,]

-- I am wondering, why isn't there an R scoping rule that search starts with the dataframe names, as if we'd said

with(df, df[colname==value,])

-- wouldn't that be a reasonable default to prepend to the name search path?

Cheers,
Alexy

______________________________________________
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.

Reply via email to