Skip to content

wrap balT() formula arg in as.formula() #118

@benthestatistician

Description

@benthestatistician

In an example I'm working with I got

> covariates %>% setdiff("adjcnt_a20_64") %>%
+     paste(collapse="+") %>% paste("z ~", .) %>% 
+ balanceTest(counties, unit.weights=adjcnt_a20_64)
Error: $ operator is invalid for atomic vectors

Was able to get it to run by

covariates %>% setdiff("adjcnt_a20_64") %>%
    paste(collapse="+") %>% paste("z ~", .) %>%
    as.formula() %>%
balanceTest(counties, unit.weights=adjcnt_a20_64)

Perhaps this is something we can take care of rather than leaving it to the user to figure out? (proj1-balT@ec7b1ee)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions