When printing an adjustment set where one of the sets is empty, there is a visual inconsistency in the empty set vs the others. The empty set is off to the right by a few characters.
library(dagitty)
dagitty("x -> y; z -> y") |>
adjustmentSets(exposure = "x", outcome = "y", type = "all")
#> {}
#> { z }
When printing an adjustment set where one of the sets is empty, there is a visual inconsistency in the empty set vs the others. The empty set is off to the right by a few characters.
Created on 2024-06-18 with reprex v2.1.0
This PR uses
writeLines()
instead ofcat()
to match the output of other sets.