pbreheny / visreg

Visualization of regression functions
http://pbreheny.github.io/visreg/
61 stars 18 forks source link

Adding points to visreg2d plot #114

Closed MarcoVuerich closed 1 year ago

MarcoVuerich commented 1 year ago

Hello, I'm struggling trying to add the real values into the visreg2d plot.

I'm working this way:

fit <- lm(Ozone ~ Solar.R * Wind,    data=airquality)
visreg2d(fit,x="Wind",y="Temp",plot.type="gg") +geom_point( ???? )

but I cannot figure out what to insert in geom_point for having just the values of my dataset and not all the dots of the matrix that visreg2d creates.

Any help? Thank you

pbreheny commented 1 year ago

http://pbreheny.github.io/visreg/articles/web/faq.html#q-in-visreg2d-is-it-possible-to-superimpose-data-points-onto-the-plot