I was recently looking for a way to remove unwanted variables from a draws object, and I found that there is a remove_variables function (mentioned by in #331) but it does not seem to be exported. Is this intentional?
Here, the generic is not exported, but the individual methods appear to be:
https://github.com/stan-dev/posterior/blob/1210f4a42eeb6b942572097d60a8cc2fb8540adf/R/remove_variables.R#L1C1-L14C2
Perhaps another option would be to add an exclude parameter in subset_draws (e.g. subset_draws(example_draws(), variable = "theta", exclude = TRUE) would remove all theta variables)
I was recently looking for a way to remove unwanted variables from a draws object, and I found that there is a
remove_variablesfunction (mentioned by in #331) but it does not seem to be exported. Is this intentional?Here, the generic is not exported, but the individual methods appear to be:
https://github.com/stan-dev/posterior/blob/1210f4a42eeb6b942572097d60a8cc2fb8540adf/R/remove_variables.R#L1C1-L14C2
Perhaps another option would be to add an
excludeparameter insubset_draws(e.g.subset_draws(example_draws(), variable = "theta", exclude = TRUE)would remove all theta variables)