The asterisk (*) can be used as a wildcard, for a compact
notation of csquares. expand_wildcards
will replace all
wild cards with valid combinations of values and expands
the compact notation to an explicit notation without
wildcards.
Check out vignette("wildcards")
for more details.
expand_wildcards(x, csquares, ...)
Returns a csquares
object with full notation
expand_wildcards("1000:*")
#> csquares [1:1] 4 squares
expand_wildcards("1000:***")
#> csquares [1:1] 100 squares
expand_wildcards("1000:1**")
#> csquares [1:1] 25 squares
expand_wildcards("1000:***:*")
#> csquares [1:1] 400 squares
expand_wildcards(c("1000:*", "1000:***", "1000:1**", "1000:***:*"))
#> csquares [1:4] 4 squares, 100 squares, 25 squares, 400 squares
expand_wildcards(data.frame(csq = "1000:*", foo = "bar"), csquares = "csq")
#> csq foo
#> 1 4 squares bar