n <- 200
df <- tibble(
iss = rnorm(n, 25, 12),
los = 2 + 0.4 * iss + rnorm(n, 0, 5)
)
fit <- lm(los ~ iss, data = df)
df$fitted <- fitted(fit)
ggplot(df, aes(iss, los)) +
geom_point(alpha=0.4, color="#475569") +
geom_smooth(method="lm", color="#2563eb", se=TRUE) +
labs(title="Linear regression: ISS → Hospital LOS",
x="Injury Severity Score", y="Length of Stay (days)") + theme_di()

