Run ❯
Get your
own
website
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
# Specify the sample occurences (x), the sample size (n), and the null-hypothesis claim (p) x <- 10 n <- 100 p <- 0.5 # Calculate the sample proportion p_hat = x/n # Calculate and output the test statistic (p_hat-p)/(sqrt((p*(1-p))/(n)))
[1] -8