Closed zander-prinsloo closed 8 months ago
Create is_balanced function and documentation. There are no tests yet.
is_balanced
Please check whether it makes sense and whether it does what you intend it to.
The example that I used in documentation are also given below:
x1 = data.frame(id = c(1L, 1L, 2L, 3L, NA_integer_), t = c(1L, 2L, 1L, 2L, NA_integer_), x = 11:15) is_balanced(df = x1, by = c("id", "t"), return = "table") # returns combo of "id" and "t" not in df #> id t #> 1 3 1 #> 2 2 2 is_balanced(df = x1, by = c("id", "t"), return = "logic") # returns TRUE or FALSE #> [1] FALSE
Create
is_balanced
function and documentation. There are no tests yet.Please check whether it makes sense and whether it does what you intend it to.
The example that I used in documentation are also given below: