For boolean/logical variables without missings I get the following error. It works if I transform the variables to factor beforehand, or if they have missings.
data("iris")
iris$Sepal.Width = sample(c(F, T), replace = T, size = nrow(iris))
library(synthpop)
#> Loading required package: lattice
#> Loading required package: MASS
#> Loading required package: nnet
#> Loading required package: ggplot2
x = syn(iris)
#> syn variables
#> 1 Sepal.Length Sepal.Width Petal.Length
#> Error: variable 'Sepal.Width' was fitted with type "logical" but type "numeric" was supplied
For boolean/logical variables without missings I get the following error. It works if I transform the variables to factor beforehand, or if they have missings.