va_mixed is a wrapper around va on all possible VA notations. By default, c("snellen", "etdrs", "logmar", "snellendec") will be converted - in that order! For tricky cases see details and examples. Note that va_mixed will not give nice messages which values are transformed from which notation, and which values were replaced with NA.
va_mixed(x, to, possible)
vector with mixed VA entries
to which notation to be converted
which possible VA notations - and the precedence given, see details
x <- c(NA, "nlp", 1:2, 1.1, -1, "20/40", "4/6", "6/1000", 34) va_mixed(x, to = "snellen")
va_mixed(x, to = "snellen", possible = c("snellen", "snellendec"))
less than 4" va_mixed(x, to = "snellen", possible = c("snellen", "logmar", "etdrs"))
Mixed entries are challenging, but unfortunately seem to occur in real life data. It will be fairly individual what you have in yours, but it should hopefully not happen that you have all possible notations. Snellen fractions are usually not challenging because they contain a "/", thus are easy to recognize.
Most problematic are values between 0 and 3,
in particular full integers - this can be EDTRS, snellen decimal notation
or logmar. If your data doesn't have snellen decimal notation,
specify this with "possible", e.g. with
possible = c("snellen", "etdrs", "logmar")
. If you know that you don't
have any ETDRS value less than 4, you can safely give precedence to logmar
instead, like this: possible = c("snellen", "logmar", "etdrs")
@examples
Other Ophthalmic functions:
va()
Other VA converter:
VAwrapper
,
plausibility_methods
,
snellen_steps
,
va_methods
,
va()
,
which_va()