I am confused about the formula here about standard error.
I know that standard error of the sample average Y_bar should be an estimator of the standard deviation of the sampling distribution $\bar Y$. This should be based on the case where the population std is unknown. The formula should be SE[$\bar Y$] = sample standard deviation / sqrt(n).
However, i am considering the case where i know i am drawing samples from a Bernoulli distribution; this has two cases.
I know it is Bernoulli, but I don't know its real p(probability of success). Then I shouldn't know its variance. Then the methods to compute SE should be using the formula above. For example, Y1 = 0, Y2 = 1, Y3 = 1. Then sample variance is 1/2 * [(0 - 2/3) ** 2 + 2*(1-2/3)**2) = A. so the sample SE should be $\sqrt{\frac{A}{n}}$, which is different from $\sqrt{\frac{\bar Y*(1 - \bar Y) }{ n} }$. (which formula is correct?)
I know it is Bernoulli and I know its real p. Then I should know the sample variance to be p * (1-p) / n, the sample standard deviation is the square root of sample variance. Then we probably don't even need to estimate sample standard error. As it is the same as sample standard deviation.
However, the following statement makes me confusing: When Yi are iid draws from a Bernoulli distribution with success probability p, the variance of $\bar Y$ should be p * (1-p)/n, and SE[$\bar Y$] is $\sqrt{\frac{\bar Y * (1-\bar Y) }{ n}}$. I am not sure, why when computing SE, we don't use p, but use $\bar Y$ instead.