use quotation marks within R's paste function -


i try use as.formula() paste() build regression equation.

the follwoing example works well: as.formula(paste("y ~ 1 + x1 +", paste("y", 2, sep=""), sep="")).

however, how use quotation marks within paste()? line fails: as.formula(paste("y ~ 1 + x1 + fx(x2, m="abc")", paste("y", 2, sep=""), sep="")). in advance...


Comments