If the outcome of a data generating process is always a 0 or 1, is the variance of the sample npq? Or is this variance formula only applicable when the data generating process is as simple as 'draws from a binomial distribution?
For example, let's say I have a process that draws two random numbers between 0 and 1. If the first number is > 0.5 and the second random number is < 0.1, then the outcome is a 1, otherwise, it's a 0. So p = 0.05 and q = 0.95, so for n = 100, sample variance = 4.75.
Is 4.75 the sample variance, or does the data generating process that creates the 0s and 1s influence the sample variance?