# Example dataset
data <- data.frame(
x = rnorm(100, mean = 50, sd = 10),
y = 3 + 0.5 * rnorm(100, mean = 50, sd = 10) + rnorm(100)
)
# Run a regression model
my_model <- lm(y~x, data)
# Create plot with regression line, confidence limits, and prediction limits
lm_plot(my_model)
# Customize plot labels
lm_plot(my_model) + xlab("Your x-axis label") + ylab("Your y-axis label")
Run the code above in your browser using DataLab