One Sample Score Test of a Proportion

Where ${\displaystyle g}$ is the observed proportion, ${\displaystyle e}$ is the expected proportion, ${\displaystyle n}$ is the effective sample size, and ${\displaystyle d_{eff}}$ is Extra deff:
${\displaystyle z={\frac {g-e}{\sqrt {d_{eff}e(1-e)/n}}}}$
where ${\displaystyle p\approx 2(1-\Phi (|z|))}$ if ${\displaystyle |g-e|\geq 0.0001}$ and NaN otherwise.