Confidence Interval Week 3/Module 3

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/22

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

23 Terms

1
New cards

Confidence interval

  1. 95% interval → means that we are 95% confident that the true population parameter is contained within the confidence interval.

    1. If we repeatedly take random samples and construct intervals from them, about 95% of those intervals would contain the true population parameter does

  2. “plausible range where we expect our true population parameter to fall”


Writing def

  • An interval in which for 95% of samples with intervals created for them have the true mean within the interval

    • And distance between statistic and true mean is < 1.96

<ol><li><p>95% interval → means that we are 95% confident that the true population parameter is contained within the confidence interval.</p><ol><li><p>If we repeatedly take random samples and construct intervals from them, about 95% of those intervals would contain the true population parameter does</p></li></ol></li><li><p>“plausible range where we expect our true population parameter to fall”</p></li></ol><div data-type="horizontalRule"><hr></div><p>Writing def</p><ul><li><p>An interval in which for 95% of samples with intervals created for them have the true mean within the interval</p><ul><li><p>And distance between statistic and true mean is &lt; 1.96</p></li></ul></li></ul><p></p>
2
New cards

Wrong interpretations of CI

  • CI represents the probability that the true parameter value is contained within the interval

    • NO!

    • Population parameter has only 1 value, if you repeat the sampling process, the population parameter still has only 1 value

      • it is either in the interval or isn’t in it

3
New cards

Larger Confidence Intervals implications (99vs95)

  • 99% means larger intervals

    • because you need larger ranges to make sure you have a better chance to cover the true mean

    • so intervals are wider

4
New cards

Sample size and confidence intervals

  • as the sample size increases, the intervals become narrower

5
New cards

SD magnitude and confidence intervals

  • Smaller SD means narrower values

6
New cards

Formula for confidence intervals

knowt flashcard image
7
New cards
  1. used to find the appropriate standard errors in calculations

    1. qnorm(%+remaining area of left or right)

      1. or 1-CI for a and a/2 for second part

    2. so for 90% it would be (0.9+0.5) = qnorm(0.95)

8
New cards
term image
  1. 95% corresponds to 1.98 in a t-dist since the area becomes n-1 = 99

  2. t_critical <- qt(0.975, df)

9
New cards

CI depends on the sample you collect

  • since the Confidence Interval depends on a given sample

    • if you collect a different sample your CI will almost certainly be different

10
New cards

Point estimate

  1. Best estimate of the population parameter value

11
New cards

Confidence vs Precision trade-off

  1. Higher level of confidence → larger interval, less precise

12
New cards

Percentile method

  • This method sets the lower endpoint of the confidence interval at the 2.5th percentile of the bootstrap distribution and similarly sets the upper endpoint at the 97.5th percentile. The resulting interval captures the middle 95% of the values of the sample mean in the bootstrap distribution.

13
New cards

theory based CI

knowt flashcard image
14
New cards

Quantiles for the CI

knowt flashcard image
15
New cards

Z-score

knowt flashcard image
16
New cards

CI for proportion via CLT

  • ci_lower <- qnorm(0.025, phat, sqrt(phat*(1-phat)/n))

  • ci_upper <- qnorm(0.975, phat, sqrt(phat*(1-phat)/n))

17
New cards
term image
knowt flashcard image
18
New cards

R code for proportion

knowt flashcard image
19
New cards

General formula for CI for a parameter

SE^(0^) is the estimated std. error

<p>SE^(0^) is the estimated std. error</p>
20
New cards

Code for confidence interval for one mean using a t-dist

  • when specifying a quantile from a t distribution (t*), you need to specify the degrees of freedom, as well as the quantile you want

  • 1−α is the confidence level (e.g., 95% confidence means α=0.05).

  • X- is the sample mean, an estimate of mu

  • tn−1,1−α/2 is the critical t-value from the t-distribution with n−1 degrees of freedom.

  • S is the sample standard deviation (since the population standard deviation σ\sigmaσ is unknown).

  • S/sqrt(n)​ is the standard error of the mean.

<ul><li><p>when specifying a quantile from a t distribution (t*), you need to specify the degrees of freedom, as well as the quantile you want</p></li><li><p>1−α is the <strong>confidence level</strong> (e.g., 95% confidence means α=0.05).</p></li><li><p>X- is the <strong>sample mean</strong>, an estimate of mu</p></li><li><p>tn−1,1−α/2 is the <strong>critical t-value</strong> from the t-distribution with n−1 degrees of freedom.</p></li><li><p>S is the <strong>sample standard deviation</strong> (since the population standard deviation σ\sigmaσ is unknown).</p></li><li><p>S/sqrt(n)​ is the <strong>standard error</strong> of the mean.</p></li></ul><p></p>
21
New cards
<p>CI difference in proportions  </p>

CI difference in proportions

knowt flashcard image
22
New cards

t-dist code

knowt flashcard image
23
New cards

Comparison between construction of CI with and without known sigma

  1. 95% corresponds to 1.98 in a t-dist. since the area becomes n-1 = 99

    1. so then z score moves down

  2. t_critical <- qt(0.975, df)