MWE:
a = c(rep('z', 5), rep('y', 5))
tbl = tibble(a, b = 1:10)
a_prime = rep('x', 5)
add_row(tbl, a = a_prime)
This works fine.
add_row(group_by(tbl, a), a = a_prime)
This throws an error Error: is.data.frame(df) is not TRUE. It looks like, when the grouped dataframe is sent to rbind, rbind returns a matrix of dataframes. remove_rownames then (quite reasonably) doesn't know what to do with this mess a few lines later.
MWE:
This works fine.
This throws an error
Error: is.data.frame(df) is not TRUE. It looks like, when the grouped dataframe is sent torbind,rbindreturns a matrix of dataframes.remove_rownamesthen (quite reasonably) doesn't know what to do with this mess a few lines later.