[R] Why does debugging print() change output of function?
peter dalgaard
pdalgd at gmail.com
Wed Sep 10 01:07:23 CEST 2014
On 07 Sep 2014, at 00:31 , David Winsemius <dwinsemius at comcast.net> wrote:
> The goal:
> to create a function modeled after `subset` (notorious for its non-standard evaluation) that will take a series of logical tests as unqiuoted expressions to be evaluated in the framework of a dataframe environment and return a dataframe of logicals:
...
A belated peep from the author of subset(): Don't!
I think we learned the hard way by now that it is much easier to pass unevaluated expressions in the shape of formula objects or maybe expression objects. Lots of pain can be avoided by slipping in a simple "~".
--
Peter Dalgaard, Professor,
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: pd.mes at cbs.dk Priv: PDalgd at gmail.com
More information about the R-help
mailing list