Calculate the log-posterior for a 1-d binary population

logpost_binary_(N, n, Y, y, lprior)

Arguments

N

the population size

n

the sample size

Y

the number of successes in the population

y

the number of successes in the sample

lprior

function uses to calculate the log-prior