I'm trying to plot a graph logxlog and take a linear function and its equation. Wanted to have also r2, p, F... Anyone knows how to extract the equation of the linear function when you plot logxlog?? Is it possible to show in the graph? Ho do you do that?
Thanks so much,
below here the codes I did my graph:
require(ggplot2)
graph1 <- ggplot(total, aes(y=volume1, x=volume2, colour = casts)) +
geom_point()
graph1 +
scale_x_log10() +
scale_y_log10() +
geom_smooth(method = "lm", se=FALSE, color="black", formula = y ~ x)