R で ggplot2 ライブラリを使用していて、ggplot にタイトルを付けようとしていますが、ggtitle 関数が存在しないと表示されます。
これは私のコードです:
p <- ggplot (data, aes(x, y)) +
geom_point(shape= 21, fill= "blue", colour= "black", size=2) +
xlab("X Value") + ylab("Y Value") +
geom_smooth(method= "lm", se= FALSE, colour= "red", formula=y ~ poly(x, 3, raw=TRUE)) +
geom_errorbar(aes(ymin=y-SE, ymax=y+SE), width=.9)
p
私はこれを試しましたが、うまくいきません:
p <- ggplot (data, aes(x, y)) +
geom_point(shape= 21, fill= "blue", colour= "black", size=2) +
xlab("X Value") + ylab("Y Value") +
geom_smooth(method= "lm", se= FALSE, colour= "red", formula=y ~ poly(x, 3, raw=TRUE)) +
geom_errorbar(aes(ymin=y-SE, ymax=y+SE), width=.9) +
ggtitle( "title")
p
どんな助けでも大歓迎です!