The code seems to stop at the call to plot() in the code below, and then
MS's error reporting window pops up and informs us that rgui has been
closed.
Note that the same code, but without the postcript() and dev.off()
commands works as expected to produce the plot on a windows device.
Any ideas as to what is going on?
All the best,
Gav
#code to run to reproduce the problem
year <- c(1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
1998, 1999, 2000, 2001, 2002)
avgMsr <- c(10.800000, 7.000000, 6.200000, 9.571429, 10.800000,
11.600000, 10.200000, 11.400000, 7.200000, 9.400000, 11.200000,
11.600000, 11.600000, 8.000000, 7.600000)
totMsr <- c(19, 17, 13, 24, 17, 17, 21, 18, 13, 15, 19, 18, 21, 15, 11)
postscript(file="invert.eps", onefile=FALSE, horizontal = FALSE,
pointsize = 8)
op <- par(mar = c(3,4,1.5,1)+0.1,font.main=16,tcl=-0.2)
plot(x = year, y = avgMsr, ylab = "Species richness", main = "Loch Coire
nan Arr", axes = FALSE, ylim = c(0,25), xlim = c(1988,2002))
axis(2, las=1)
axis(1)
lines(x = year, y = avgMsr)
points(x = year, y = totMsr , col = "black", pch = 19, type = "o")
lines(x = year, y = totMsr)
box()
par(op)
dev.off()