## Confidence Interval from LOESS dissapears when using weights with geom_smooth command

Question

In R, using the ggplot2 package, I have these two lines:

```
ggplot(data, aes(x = x, y = Pinera)) +
geom_point(shape = 1) +
geom_smooth(method = loess, se = TRUE)
ggplot(data, aes(x = x, y = Pinera, weight = pesos)) +
geom_point(shape = 1) +
geom_smooth(method = loess, se = TRUE)
```

The first one gives me an unweighted smooth curve from my data with the shaded confidence interval, however when I add the weights, the confidence interval region disappears despite I stated `se = TRUE`

.

This is my data

Show source

## Answers ( 0 )