I was doing an online course, and the course seemed to suggest that the confidence interval says is that if we have a statement such as the following:
We are XX% confidence interval for some sample statistic is between $\pm$ y.
What this means is that if we take a sample from the population, we can be sure that XX% of the time, the true population statistic will be within: sample statistic $\pm$ y.
I am not sure why this is the case. I was under the impression that the confidence interval gave us a way to tell whether or not the sample statistic was within a certain interval of the true population mean.
Can someone pleas help me understand this?
Given a sample you can find a confidence interval. The larger the sample, the narrower the interval. A different sample will give a different confidence interval, so that we generate a set of random intervals. For a 95% confidence interval we are saying that, 95% of the time, such a random interval will contain the true population parameter. It is all about the weight of evidence for the true parameter value, nothing is absolutely definitive.
Typically, you might claim the population parameter value has a certain value. Then if the confidence interval you calculate contains that value, you can say that you do not have evidence to reject the value claim. This is a bit weaker than saying the parameter value IS in the interval, but we can live with it.