Skip to content
Prev 40928 / 63424 Next

'data.frame' method for base::rep()

Hello David
On Tue, Aug 2, 2011 at 4:14 PM, David Winsemius <dwinsemius at comcast.net> wrote:
Nice catch. Thanks for pointing it out.
The above is nice. I wouldn't have thought of it.
Your solution still seems more like an obscure side-effect of
subsetting than an intuitive feature, in the sense that before trying
it out the average user would probably first turn to base::rep() when
in need to replicate a df, and then (perhaps) to
mefa:::rep.data.frame() (with all the associated confusion and
pitfalls). I would tend to believe that if there is a clean R-ish way
to implement a base::rep.data.frame() it could still be useful.

Best regards
Liviu