ich habe ein Problem. Und zwar finde ich den Fehler nicht. Warum wird die Grafik auf der X-Achse nicht richtig dargestellt?
Hoffe ihr könnte mir weiterhelfen. Danke!library(ggplot2)
ggplot(xom,aes(Date,Adj.Close, group=1))+
geom_line(aes(color="xom"))+
geom_line(data=bp,aes(color="bp"))+
labs(color="Legend")+
ylab("Close Price, USD")+
scale_colour_manual("",breaks=c("xom","bp"),
values = c("blue","brown"))+
theme(plot.title = element_text(lineheight = .7, face="bold"))+
annotate("text",x=xom[which.max(xom$Adj.Close),1],y=max(xom$Adj.Close),label="90,06", cex=2.1)+
annotate("text",x=bp[which.max(bp$Adj.Close),1],y=max(bp$Adj.Close),label="40,17", cex=2.1)
max(xom$Adj.Close)
which.max(xom$Adj.Close)
max(bp$Adj.Close)
which.max(bp$Adj.Close)