I've started using Sweave and having a problem The code in Lyx is
library (car)cabbages$Year<-recode(cabbages$Year,'"X2001"="2001";"X2002"="2002";"X2003"="2003"; etc
But its appearing in the PDF as> cabbages$Year <- recode(cabbages$Year, "\"X2001\"=\"2001\";\"X2002\"=\"2002\";\"X2003\"=\"2003\";\ etc
And obviously isn't working as printing out incorrectly. Can anyone suggest what is happening here. Many thanks, Graham