Standard error for proportion with small sample size

Standard error for a proportion, when n > 5 and np > 5 is calculated as $$SE = \sqrt{ \frac{p(1-p)}{n}}$$ where p is the proportion and n is sample size.

However, for even smaller samples, we were given an equation $$SE=\frac{1-e^{\frac{log(0.05)}{n}}}{1.96}$$

Is the second formula a valid way to calculate standard error of a proportion for very small samples? What is the rationale behind it?

• From where is the second formula? It doesn't depend on $p$ and already contains some quantiles (i.e. 1.96). So I wonder how it can be called a standard error at all? – COOLSerdash Mar 9 '17 at 13:47
• @COOLSerdash We were asked to calculate this by a reviewer, without a reference. That's why I hope someone might be able to figure out what this means. – nya Mar 9 '17 at 14:20
• Somebody is confused. This appears related to constructing a confidence interval for a proportion when no successes are observed in $n$ independent iid Bernoulli observations. The standard error formula $\sqrt{p(1-p)/n}$ is correct for any $p$ and $n$. When $p$ is unknown (as it usually is), one substitutes an estimate for $p$ in this formula--and the result is still called the standard error. It makes a poor input to a confidence limit calculation even when $np \approx 5$: don't use Normal-theory formulas until $np$ and $n(1-p)$ are much larger than that. – whuber Mar 9 '17 at 15:08
• @whuber Thank you. Would you turn this into an answer so that you could get credit for it? – nya Mar 10 '17 at 6:58

(It is worth noting that the above paper actually recommends either the Wilson interval, the Agresti interval or the Jeffries interval, but I couldn't find an online calculator for those; there are many in software packages. For example, in Matlab [p, ci] = binofit([positives], [sample size]) gives you a confidence interval via the Agresti method).