# NOT RUN {
merge.formula(y ~ x1, ~ x2) ## -> y ~ x1 + x2
f2 <- merge.formula(y ~ x1*x2, z ~ (x2+x4)^3)
f. <- merge.formula(y ~ x1*x2, ~ (x2+x4)^3) # no LHS for 2nd term
f2
stopifnot(f2 == f.)
# }
Run the code above in your browser using DataLab