I have data covering a time period of over 25 years and I would like to see the years on the x-axis.
dates <- as.Date(Dollar[,1], "%d.%m.%Y")
Dollar <- as.xts(Dollar[,2], dates)
plot(SWEDOLall, xaxt = "n", main="SMA", ann = FALSE)
axis.Date(side = 1, dates, at = labDates, format = "%y", labels = TRUE)
title(ylab = "Value")
title(xlab = "Time")
But my x-axis is just blank. Can anybody see what mistake I have made?