Message-ID: <CAP01uRnONpc=WnQATrcdU0xLv_Ce=RJ-TTyCfKBN+pnV0NMYbw@mail.gmail.com>
Date: 2022-01-26T14:48:21Z
From: Gabor Grothendieck
Subject: aggregate.formula and pipes
Because aggregate.formula has a formula argument but the generic
has an x argument neither of these work:
mtcars |> aggregate(x = mpg ~ cyl, FUN = mean)
mtcars |> aggregate(formula = mpg ~ cyl, FUN = mean)
This does work:
mtcars |> stats:::aggregate.formula(formula = mpg ~ cyl, FUN = mean)
Suggest that aggregate.formula be exported.
--
Statistics & Software Consulting
GKX Group, GKX Associates Inc.
tel: 1-877-GKX-GROUP
email: ggrothendieck at gmail.com