SDS 2020 #2

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/26

encourage image

There's no tags or description

Looks like no tags are added yet.

27 Terms

1
New cards

Bernoulli Random Variable (List Mean, SD, Variance)

An individual trial has only two possible outcomes: success or failure

E(X)=μE\left(X\right)=\mu

S(D)=p(1−p)S\left(D\right)=\sqrt{p\left(1-p\right)}

Var(X)=p(1−p)Var\left(X\right)=p\left(1-p\right)

<p>An individual trial has only two possible outcomes: success or failure</p><p>$$E\left(X\right)=\mu$$ </p><p>$$S\left(D\right)=\sqrt{p\left(1-p\right)}$$ </p><p>$$Var\left(X\right)=p\left(1-p\right)$$ </p>
2
New cards

Geometric Random Variable (Probability, Mean, SD, Variance)

How many independent Bernoulli trials it takes to observe a success; X=number of trials until first success

P(X)=(1−p)k−1pP\left(X\right)=\left(1-p\right)^{k-1}p

E(X)=μ=1pE\left(X\right)=\mu=\frac{1}{p}

SD(X)=1−pp2SD\left(X\right)=\sqrt{\frac{1-p}{p^2}}

Var(X)=1−pp2Var\left(X\right)=\frac{1-p}{p^2}

3
New cards

Binomial Random Variable

P(X=k)=(nk)pk(1−p)n−kP\left(X=k\right)=\left(\frac{n}{k}\right)p^{k}\left(1-p\right)^{n-k}

(nk)=n!(n−k)!⋅k!\left(\frac{n}{k}\right)=\frac{n!}{\left(n-k\right)!\cdot k!}

E(X)=μ=npE\left(X\right)=\mu=np

SD(X)=np(1−p)SD\left(X\right)=\sqrt{np\left(1-p\right)}

Var(X)=np(1−p)Var\left(X\right)=np\left(1-p\right)

<p>$$P\left(X=k\right)=\left(\frac{n}{k}\right)p^{k}\left(1-p\right)^{n-k}$$ </p><p>$$\left(\frac{n}{k}\right)=\frac{n!}{\left(n-k\right)!\cdot k!}$$</p><p>$$E\left(X\right)=\mu=np$$</p><p>$$SD\left(X\right)=\sqrt{np\left(1-p\right)}$$</p><p>$$Var\left(X\right)=np\left(1-p\right)$$</p>
4
New cards

Negative Binomial Random Variable

Definition: Number of independent Bernoulli trials until the 𝑘𝑡ℎ success,


P(X=k)=(nk)pk(1−p)n−kP\left(X=k\right)=\left(\frac{n}{k}\right)p^{k}\left(1-p\right)^{n-k}

(nk)=n!(n−k)!⋅k!\left(\frac{n}{k}\right)=\frac{n!}{\left(n-k\right)!\cdot k!}

E(X)=μ=kpE\left(X\right)=\mu=\frac{k}{p}

SD(X)=k(1−p)p2SD\left(X\right)=\sqrt{\frac{k\left(1-p\right)}{p^2}}

5
New cards

Poisson Random Variable

Used to count the number of times an event occurs in an interval of time or space.

P(X=k)=e−λλklk!P\left(X=k\right)=\frac{e^{-\lambda}\lambda^{kl}}{k!}

λ\lambda =rate at which events occur

E(X)=μ=kpE\left(X\right)=\mu=\frac{k}{p}

SD(X)=k(1−p)p2SD\left(X\right)=\sqrt{\frac{k\left(1-p\right)}{p^2}}

6
New cards

Normal Distribution

-Symmetrical

-Unimodal

N(μ,σ)N\left(\mu,\sigma\right)

N(0,1)N\left(0,1\right)

7
New cards

Z Score

Z=x−μσZ=\frac{x-\mu}{\sigma}

8
New cards

pnorm

Gives area under curve for certain Z score

9
New cards

CLT

When observations are independent and the sample size 𝑛 is sufficiently large, phat tends to follow a normal distribution

μp=phat\mu_{p}=p_{hat}

SEphat=p(1−p)nSE_{phat}=\sqrt{\frac{p\left(1-p\right)}{n}}

10
New cards

Practice Problem: A part of a quality control process for computer chips, an engineer at
a factory randomly samples 212 chips during a week of production to test the current rate of chips with severe defects. She finds out that 27 of the chips are defective. The historical rate of defects is 10%. Should the engineer be surprised by the observed rate of defects during the current week


11
New cards

Confidence Interval for One Proportion

Conditions: nphat>10 and n(1-phat)>10

(p^−MOE,p^+MOE)\left(p̂-MOE,p̂+MOE\right)

MOE=z⋅⋅SEphatMOE=z^{\cdot}\cdot SE_{phat}

12
New cards

Hypothesis Test for One Proportion

Conditions: np0>10 and n(1-p0)>10

Null: H0: p=population proportion

Alternate: HA: p does not equal population proportion

13
New cards

Confidence Interval for Difference of Two Proportions

Check CLT: n1phat1>10 n1(1-phat)>10 n2phat2>10 n2(1-phat2)>10


(p^−MOE,p^+MOE)\left(p̂-MOE,p̂+MOE\right)

MOE=z⋅⋅SEphatMOE=z^{\cdot}\cdot SE_{phat}

SE=p1(1−p1)n1+p2(1−p2)n2SE=\sqrt{\frac{p_1\left(1-p_1\right)}{n_1}+\frac{p_2\left(1-p_2\right)}{n_2}}

Use phat1 and phat 2 when p1 and p2 are unknown

<p>Check CLT: n1phat1&gt;10 n1(1-phat)&gt;10 n2phat2&gt;10 n2(1-phat2)&gt;10</p><p></p><p>$$\left(p̂-MOE,p̂+MOE\right)$$ </p><p>$$ MOE=z^{\cdot}\cdot SE_{phat} $$ </p><p>$$SE=\sqrt{\frac{p_1\left(1-p_1\right)}{n_1}+\frac{p_2\left(1-p_2\right)}{n_2}}$$ </p><p>Use phat1 and phat 2 when p1 and p2 are unknown</p>
14
New cards

Hypothesis Test for Difference of Two Proportions

Check CLT using p pooled

Z=(p1−p2)−0SEZ=\frac{\left(p_1-p_2\right)-0}{SE}

SE=ppooled(1−ppooled)n1+ppooled(1−ppooled)n2SE=\sqrt{\frac{p_{pooled}\left(1-p_{pooled}\right)}{n_1}+\frac{p_{pooled}\left(1-p_{pooled}\right)}{n_2}}

<p>Check CLT using p pooled</p><p>$$Z=\frac{\left(p_1-p_2\right)-0}{SE}$$ </p><p>$$SE=\sqrt{\frac{p_{pooled}\left(1-p_{pooled}\right)}{n_1}+\frac{p_{pooled}\left(1-p_{pooled}\right)}{n_2}}$$ </p>
15
New cards

Critical Value Approach

Compare Z score to known critical value

CV: -qnorm(alpha/2)

16
New cards

P value Approach

Compute p value and compare to significance level

2pnorm(abs(Z))

17
New cards

Practice Problem 2: In New York City on October 23rd, 2014, a doctor who had recently been treating Ebola patients in Guinea, went to the hospital with a slight fever and was subsequently diagnosed with Ebola. Soon thereafter, a poll found that 82% of New Yorkers favored a “mandatory 21-day quarantine for anyone who has come in contact with an Ebola patient.” This poll included response of 1,042 New York adults. Compute a 90% confidence interval for the proportion of all New Yorkers who favored a quarantine period


18
New cards

Practice Problem 3: A survey of 1016 American youths age 8-18 in 2004fo und that 690 had television in their bedroom. Construct a 99% CI


19
New cards

Practice Problem 4: A genetic model suggests that a particular experimental cross of lupine should have blue flowers with probability 0.75 and white flowers with probability 0.25. In an experiment with 200 seeds, 142 are blue flowering. Is this consistent with the model?


20
New cards

Type 1 Error

Reject H0 when it is actually true

21
New cards

Type 2 Error

Fail to reject H0

22
New cards

Calculating Desired MOE

knowt flashcard image
23
New cards

Practice Problem 6: A 2006 article in the Washington Post claimed that 15% of high school students used cursive writing on the essay portion of the SAT exam in 2005-06. Suppose we want to estimate this proportion for the following year. How many essays would we need to sample to estimate this proportion to within 0.04 with 95% confidence

24
New cards

Practice Problem 7: Extra practice: Suppose 84% of a random sample of 125 nurses working 7am to 3 pm shifts in city hospitals express positive job satisfaction, while only 72% of a random sample of size 150 nurses on the 11pm to 7am shifts express similar fulfillment. Compute a 99% confidence interval for the difference in proportions of job satisfaction

25
New cards

Chi Squared GOF

Used for binned data

∑(O−E)2E\sum_{}^{}\frac{\left(O-E\right)^2}{E}

DF=#categories-1

26
New cards

Chi Squared GOF Requirements

Observations independent of one another, expected counts greater than 5

27
New cards

pchisq and qchisq

pschisq gives the area below the curve for given Chi squared value

qchisquare gives the chi square value for given area