How may I select all unlabeled values of variables which - except for those values - have a value label, and list only those unlabeled values?
The thing is, the value labels have upto thousands of labeled values, and just a few unlabeled ones - and this is the case for several variables.
So far, I happened to find out, which variables I have to deal with (1). Knowing the specific values at stake (2), would be even better
Code:
*(1) findname *, vallabeltext("") local(missingvl) *(2) foreach v of var `missingvl' {
fre `v' if (substr(`"` : value label `v''"', 1, 2) == "") //only would output (if present) variables with all vaules being unlabeld
}
I also tried ...
Code:
foreach v of var `missingvl' {
quiet labelbook `: value label `v'' fre `v' if (substr(`"``r(null)''"') // ...but got invalid syntax here :(
}
Greetings
0 Response to output all unlabeled values of variables with value label
Post a Comment