The new haven release (2.3.0) adds the classes "vctrs_vctr" and "double" besides the class "haven_labelled" to factor variables. See example below (I can't add a STATA file for testing, but this happens to any STATA or SPSS file with labelled variables upon loading in R using read_sav or read_dta from the haven 2.3.0 package).
Therefore, the variables of class haven_labelled are not converted to class factor, which in turn causes an error upon loading and processing the files in sdcApp.
A solution is to ignore other classes of a variable besides the first class, e.g., by using
The new haven release (2.3.0) adds the classes "vctrs_vctr" and "double" besides the class "haven_labelled" to factor variables. See example below (I can't add a STATA file for testing, but this happens to any STATA or SPSS file with labelled variables upon loading in R using read_sav or read_dta from the haven 2.3.0 package).
The additional classes lead to a failure to detect the variables of class haven_labelled in line 458 of GUIfunctions.R.
#cl_lab <- which(sapply(res, class) %in% c("labelled", "haven_labelled"))
Therefore, the variables of class haven_labelled are not converted to class factor, which in turn causes an error upon loading and processing the files in sdcApp.
A solution is to ignore other classes of a variable besides the first class, e.g., by using
Then variables of class haven_labelled will be properly detected and converted to class factor.