0
$\begingroup$

I have a scatter plot that displays the trust in a country's scientists vs trust in scientists globally. based on data I created a scatter plot am trying to understand the confidence band in this picture or does it there a different interpretation to this?

confidence babd

ggplot(data_scatterplot_scient, aes(x=scientglob, y=scientloc)) +
  geom_point(col="blue", alpha = 0.5) + 
  geom_text(label=data_scatterplot_scient$country)+
  xlab("Trust in country's scientists")+
  ylab("Trust in scientists globally")+
  ggtitle("Plot for trust among citizens in Country's scientists for 12 different countries")+
  geom_smooth(method = "lm")

> dput(head(data_scatter_scient))
structure(c("Australia", "Brazil", "Croatia", "Finland", "France", 
"Germany", "7.31641791044776", "8.40596330275229", "6.19024390243902", 
"6.43867924528302", "6.1965811965812", "5.90909090909091", "5.61940298507463", 
"8.61123853211009", "6.60975609756098", "5.69483568075117", "5.82327586206897", 
"4.77818181818182"), .Dim = c(6L, 3L), .Dimnames = list(NULL, 
    c("country", "scientloc", "scientglob")))

Does the confidence band mean that the points (countries) are significant to consider and the outside points are outliers? I am a little confused about the grey band surrounding the regression line.

$\endgroup$

1 Answer 1

1
$\begingroup$

The grey band is a 95% confidence interval for the regression line. It does not say anything about points lying within or outside of the grey area - but you can visually see, whether the upper or lower limit of the regression intervall both show an ascending or descending trend. If so, the slope is significant.

For an example with a non-significant slope try

library(ggplot2)
data.frame(x = rnorm(100), y = rnorm(100)) |>
  ggplot(aes(x = x, y = y)) +
    geom_point() +
      geom_smooth(method = "lm")

enter image description here

You can use you visual intuition to "see" whether the correlation is clearly not significant, almost significant or significant. Extra: Change the values 100 in my example code to smaller or larger values to get an impression of how the more or less certain regression line has a larger or smaller 95%-CI.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.