I refer to this link for calculating the sample size needed based on the width confidence interval needed, and the guessed proportion. I realize that it is use the "asymptotic" method when calculating the sample. Having know that the "wilson" method is a better way for estimating the CI for proportion[a]. I wonder if there is any "wilson" method for estimating the sample size? (Preferably a package used in R), thanks.
[a]: A. Agresti and B.A. Coull, Approximate is better than "exact" for interval estimation of binomial proportions, American Statistician, 52:119–126, 1998.