This is a test version of Biostars. For the public version, visit https://www.biostars.org.
ggplot2 loess curve application to 2 dataframes

Hi I am trying to create a loess curve for two dataframes within the same plot with a different span value for each, not sure exactly how to go about that, here is my code thus far which adds the loess curve to both sets of data but with the same span value. Thanks.

ggplot(dplyr::bind_rows(frame_P1,frame_P2, .id = 'source'), aes(V1, V2, color = source)) + geom_point() + geom_smooth(method="loess", span=.13)
ggplot2 ggplot

0 answers

No answers yet.

Log in to answer this question.