プロットに指数 (+ べき乗) (トレンド) 線を追加したいと考えています。私はggplot2パッケージを使用しています。
私はこのようなものを持っています(もっと多くのデータがあります):
require(ggplot2)
df <-read.table("test.csv", header = TRUE, sep = ",")
df
meta temp
1 1.283 6
2 0.642 6
3 1.962 6
4 8.989 25
5 8.721 25
6 12.175 25
7 11.676 32
8 12.131 32
9 11.576 32
ggplot(df, aes(temp, meta)) +
ylab("Metabolism") + xlab("Temperature") +
geom_point() +
theme_bw() +
scale_x_continuous(limits = c(0, 35)) +
scale_y_log10()
私はこれが指数関数で表現されるべきであることを知っています. 同様に、パワーフィットも可能ですか?
関数にはこの機会がありますか、またはパッケージに使用すべきstat_smooth()
他の関数がありますか?ggplot2