Dear all
I am trying to make an interaction plot among 6 variables; e.g. PH to be in the x axis and the rest 5 variables in the y axis. The code that I am using is the below: The name of my file is e.g. spec so > spec<-read.csv("spec.csv") >head (spec) >str(spec) >names<-names(spec)[2:6] >speclong <- reshape(spec, idvar = "id", varying = list(names), >v.names="outcome",direction = "long") >speclong$time2<-factor(speclong$time,labels=rep(" ",5)) >interaction.plot(speclong$PH,speclong$time2,speclong$outcome, xaxt="n", >type="l", log="y", trace.label="",col=rainbow(8)) what I want is to change the labels of the x axis. If for example I don't use xaxt="n", by default it shows some values of PH e.g. 4.93, 5.97, 6.23, 6.47, 6.59, 6.77, 6.89, 7.35 but it don't show the ticks in each value. However I would like to define the x values e.g. 5.0, 5.5, 6.0, 6.5, 7.0. I used the xlim but it says error as well >axis(1, at=c(5.0, 5.5, 6.0, 6.5, 7.0)) but still there is a problem. Does anyone know how I can define that? Thank you in advance. Kind regards Maria [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.