search for: qica

Displaying 1 result from an estimated 1 matches for "qica".

Did you mean: qca
2002 Sep 30
4
2 plots sharing axis / combining factors
...factor variables in a single factor variable which is the combination of the other 2. Example: lith: a factor 2 levels "ca", "ma" sp: a factor with 2 levels, "ph", "qi" and I'd like to obtain: splith: a factor with 4 levels: phma, phca, qima, qica on way is by using ifelse: splith <- as.factor(ifelse(sp=="ph", ifelse(lith=="ma", "phma", "phca"), ifelse(lith=="ma", "qima", "qica"))) which works fine, but I've got the feeling that it can be done in a more efficient...