Hi,
Does anyone know how I can plot three time series within one graph?
I am running a time series analysis -
I did use the following codes:
########time serie 1
Y <- ts (finalst[,1], start=c (2016,1), frequency = 12)
autoplot(Y)
autoplot(decompose (Y))
########time serie 2
x <- ts (finalst[,2], start=c (2016,1), frequency = 12)
autoplot(x)
autoplot(decompose (x))
########time serie 3
z <- ts (finalst[,3], start=c (2016,1), frequency = 12)
autoplot(z)
autoplot(decompose (z))
My codes work perfectly individually, but I don't know how to plot them together,
thanks -
Can you provide a reproducible example?
Perhaps use ggplot instead of using autoplot.
system
Closed
3
This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.
If you have a query related to it or one of the replies, start a new topic and refer back with a link.