Questions tagged [bernoulli-distribution]

The Bernoulli distribution is a discrete distribution parametrized by a single "success" probability. It is a special case of the binomial distribution.

Filter by
Sorted by
Tagged with
62
votes
6answers
103k views

Test if two binomial distributions are statistically different from each other

I have three groups of data, each with a binomial distribution (i.e. each group has elements that are either success or failure). I do not have a predicted probability of success, but instead can ...
57
votes
4answers
31k views

Confidence interval for Bernoulli sampling

I have a random sample of Bernoulli random variables $X_1 ... X_N$, where $X_i$ are i.i.d. r.v. and $P(X_i = 1) = p$, and $p$ is an unknown parameter. Obviously, one can find an estimate for $p$: $\...
54
votes
4answers
45k views

Logistic Regression - Error Term and its Distribution

On whether an error term exists in logistic regression (and its assumed distribution), I have read in various places that: no error term exists the error term has a binomial distribution (in ...
37
votes
3answers
23k views

Logistic Regression: Bernoulli vs. Binomial Response Variables

I want to perform logistic regression with the following binomial response and with $X_1$ and $X_2$ as my predictors. I can present the same data as Bernoulli responses in the following format. The ...
31
votes
4answers
129k views

How to derive the likelihood function for binomial distribution for parameter estimation?

According to Miller and Freund's Probability and Statistics for Engineers, 8ed (pp.217-218), the likelihood function to be maximised for binomial distribution (Bernoulli trials) is given as $L(p) = \...
28
votes
4answers
9k views

Generating correlated binomial random variables

I was wondering if it might be possible to generate correlated random binomial variables following a linear transformation approach? Below, I tried something simple in ...
24
votes
3answers
742 views

K successes in Bernoulli trials, or George Lucas movie experiment

I'm reading "The Drunkard's Walk" now and cannot understand one story from it. Here it goes: Imagine that George Lucas makes a new Star Wars film and in one test market decides to perform a crazy ...
21
votes
3answers
105k views

Expected number of tosses till first head comes up

Suppose that a fair coin is tossed repeatedly until a head is obtained for the first time. What is the expected number of tosses that will be required? What is the expected number of tails that will ...
16
votes
2answers
5k views

Correlated Bernoulli trials, multivariate Bernoulli distribution?

I'm simplifying a research question that I have at work. Imagine that I have 5 coins and let's call heads a success. These are VERY biased coins with probability of success p=0.1. Now, if the coins ...
16
votes
2answers
589 views

Sampling distribution from two independent Bernoulli populations

Let's assume that we have samples of two independent Bernoulli random variables, $\mathrm{Ber}(\theta_1)$ and $\mathrm{Ber}(\theta_2)$. How do we prove that $$\frac{(\bar X_1-\bar X_2)-(\theta_1-\...
15
votes
3answers
1k views

Estimating the probability in a Bernoulli process by sampling until 10 failures: is it biased?

Suppose we have a Bernoulli process with failure probability $q$ (which will be small, say, $q \leq 0.01$) from which we sample until we encounter $10$ failures. We thereby estimate the probability ...
15
votes
3answers
7k views

Relationship between the phi, Matthews and Pearson correlation coefficients

Are the phi and Matthews correlation coefficients the same concept? How are they related or equivalent to Pearson correlation coefficient for two binary variables? I assume the binary values are 0 and ...
15
votes
2answers
28k views

Sum of Bernoulli variables with different success probabilities [duplicate]

Let $x_i$ be independent Bernoulli random variables with success probabilities $p_i$. That is, $x_i=1$ with probability $p_i$ and $x_i=0$ with probability $1-p_i$. Is there a closed expression or an ...
14
votes
2answers
8k views

Success of Bernoulli trials with different probabilities

If 20 independent Bernoulli trials are carried out each with a different probability of success and therefore failure. What is the probability that exactly n of the 20 trials was successful? Is there ...
13
votes
3answers
5k views

Sample size needed to estimate probability of "success" in Bernoulli trial

Suppose a game offers an event which upon completion, either gives a reward, or gives nothing. The exact mechanism for determining whether the reward is given is unknown, but I assume a random number ...
13
votes
2answers
874 views

Empirical distribution alternative

BOUNTY: The full bounty will be awarded to someone who provides a reference to any published paper which uses or mentions the estimator $\tilde{F}$ below. Motivation: This section is probably not ...
12
votes
1answer
2k views

Checking if a coin is fair based on how often a subsequence occurs

Results of 100 coin toss experiments are recorded as 0 for "Tails" and 1 for "Heads". The output $x$ is a string of zeros and ones of length 100. The number of times the sequence 1-...
10
votes
2answers
82k views

Maximum Likelihood Estimation for Bernoulli distribution

Let's say we have $X_1,\ldots, X_n$ iid Bernoulli($p$), ask for MLE for $p$. I'm pretty struggled on the second derivative of log-likelihood function, why it is negative? My second question is what is ...
10
votes
2answers
1k views

Fisher information matrix determinant for an overparameterized model

Consider a Bernoulli random variable $X\in\{0,1\}$ with parameter $\theta$ (probability of success). The likelihood function and Fisher information (a $1 \times 1$ matrix) are: $$ \begin{align} \...
10
votes
4answers
4k views

What is the CDF of the sum of weighted Bernoulli random variables?

Let's say we have a random variable $Y$ defined as the sum of $N$ Bernoulli variables $X_i$, each with a different, success probability $p_i$ and a different (fixed) weight $w_i$. The weights are ...
9
votes
3answers
3k views

Simulate a Bernoulli variable with probability ${a\over b}$ using a biased coin

Can someone tell me how to simulate $\mathrm{Bernoulli}\left({a\over b}\right)$, where $a,b\in \mathbb{N}$, using a coin toss (as many times as you require) with $P(H)=p$ ? I was thinking of using ...
9
votes
3answers
2k views

Sum of Products of Rademacher random variables

Let $x_1 \ldots x_a,y_1 \ldots y_b$ be independent random variables taking values $+1$ or $-1$ with probability 0.5 each. Consider the sum $S = \sum_{i,j} x_i\times y_j$. I wish to upper bound the ...
9
votes
1answer
168 views

Having a hard time with the law of the iterated logarithm

Let's say you have infinitely many i.i.d. Bernouilli variables $X_1, X_2, \cdots$ of parameter $p=\frac{1}{2}$. For instance, the binary digits of a random number. Let $S_n = X_1 + \cdots X_n$. The ...
9
votes
1answer
3k views

Sum of Product of Bernoulli and Normal Random Variables

Given $X_i \sim \mathcal{N}(\mu, \sigma^2)$ and $Y_i \sim Bernoulli(p)$, let $Z_i = X_iY_i$. I know that if $F(t)$ is the CDF of $X_i$, then $Pr[Z_i \le t] = pF(t) + (1-p)$ if $t \ge 0$ and $Pr[Z_i \...
8
votes
4answers
32k views

Maximum likelihood estimation of p in a Binomial sample

Assuming I need to find the ML estimator for p, p being the chance of success in a Binomial experiment $Bin(N,p)$, I would expect my density function to be: $$ f(y) = {{N}\choose{y}} p^y(1-p)^{N-y} $$...
8
votes
2answers
1k views

With what probability one coin is better than the other?

Let's say we have two biased coins C1 and C2 both having different probability of turning head. We toss ...
8
votes
1answer
2k views

How to generate Bernoulli random variables with common correlation $\rho$?

Suppose I want to generate $X_1, \ldots, X_n$ Bernoulli random variables such that: $$ Corr(X_i, X_j) = \rho $$ for all $i \neq j$. I am wondering what method I might be able to use (I will be ...
8
votes
3answers
313 views

What is the $p$ in Bernoulli distribution?

In the Bayesian theory of probability, probability is our expression of knowledge about a certain thing, not a property of that thing. However, I always see people treat $p$ as a parameter that needs ...
8
votes
3answers
2k views

Can Bernoulli random variables be used to approximate more than just the normal distribution?

Most statistics students are familiar with the normal approximation of the binomial distribution. And since binomial distributions are created from sums of Bernoulli random variables, it would follow ...
8
votes
3answers
425 views

Generating a min{p, 0.5} coin from a p-coin - Bernoulli factory type problem

Suppose we are given a coin with arbitrary (unknown) head probability $p$, I am wondering if there is an easy-to-implement algorithm for generating a $\min\{p, 0.5\}$ coin for any $p\in [0,1]$. ...
7
votes
3answers
5k views

How to generate correlated Bernoulli variables?

Suppose I want to simulate a survey variable in R which values derive from four binary cases $c_i$ with $i=\{1,2,3, 4\}$, each with it's probability $\Pr(c_i=1)=p_i$. Let's assume that the cases ...
7
votes
1answer
1k views

How to get the confidence interval of a Bernoulli trial if $\hat{p} = 0$?

I know the standard formula for the Bernoulli CI is: $$\hat{p}\pm z_{1-\alpha/2}\sqrt{\frac{\hat{p}(1-\hat{p})}{n}}$$ If $\hat{p} = \frac{m}{n}$ how do I estimate the confidence interval when$\ n$ ...
7
votes
1answer
185 views

Variance of Bernoulli when success probability varies

Say the success probability $X$ is a random variable with mean $\mu$ and Variance $\sigma^2$ which takes values in $[0,1]$. How can I compute the variance of a random Variable $Y$ which is 1 with ...
7
votes
1answer
4k views

CLT can be used for weighted sum of different Bernoulli variables?

Suppose $$ z_i \sim Bernoulli (p_i) $$ Can we use CLT for the following weighted sum? $$ S = \sum_i w_i z_i $$ i.e. can $S$ be approximated with a normal distribution? If yes, with which theorem? ...
7
votes
2answers
867 views

Question about joint distribution of Bernoulli random variables under constraint that sum must be 1

I am stuck with a problem at work. Can anybody please help me to give me the joint distribution of $n$ Bernoulli random variables but under the constraint that the sum of the these $n$ random ...
7
votes
1answer
3k views

Expected value of product of non independent Bernoulli random variables (correlations are known)

I've asked a question about getting the joint probability distribution for $N$ Bernoulli random variables, given the expected value for each one ($E[X_i]=p_i)$ and it's correlations ($\rho_{12},\rho_{...
7
votes
1answer
1k views

Normal Approximation of the sum of correlated Bernoulli Random Variables

Hi I am looking for a result (if it exists !!!) in the direction of Normal approximation for sum of correlated Bernoulli random variables (edit : with the same parameter $p$) where correlation between ...
7
votes
1answer
6k views

How to show operations on two random variables (each Bernoulli) are dependent but not correlated?

I was looking at the following question from "One Thousand Exercises in Probability" by Grimmett, page 25, question 16 (not homework just self-study): Let $X$ and $Y$ be independent Bernoulli ...
7
votes
2answers
412 views

Estimating successes while obtaining Bernoulli samples

I have a process which, after fixing the values of some parameters, generates samples from a Bernoulli distribution with unknown $p$. The value of $p$ is typically small, and what I want to do is to ...
6
votes
2answers
1k views

Should coin flips be modeled as Bernoulli or binomial draws in RJags?

What is the best way to model coin flips as a hierarchical model? Do you say coin draws are a series of draws from Bernoulli trials or as one draw from a binomial distribution? That is something like ...
6
votes
1answer
378 views

Why no variance term in Bayesian logistic regression?

I've read here that ... (Bayesian linear regression) is most similar to Bayesian inference in logistic regression, but in some ways logistic regression is even simpler, because there is no ...
6
votes
1answer
113 views

Is there any statistical difference between 10 Bernoulli trials and 1 binomial trial with parameter n = 10?

By "statistical difference" I mean literally any difference between the two of statistical import, beyond of course the notation or words used.
6
votes
2answers
209 views

Linear combination of discrete variables $T_i$ with $P(T_i=1)=P(T_i=-1)=1/2$

Let $T_1,...,T_n$ be iid with a Rademacher distribution; i.e., $P(T_i=1)=P(T_i=-1)=1/2$; and let $w = (w_1,...,w_n) \in \mathbb{R}^n$ without further constraints on $w$. Is there a way to compute $P(...
6
votes
2answers
2k views

The distribution of the product of a Bernoulli & an exponential random variable

Let $X$ be an exponential random variable $f(x) = c e^{-c x} \text{ if }x > 0; 0 \text{ otherwise.}$ Let $Z$ be a Bernoulli RV with $Pr(Z=1)=0.45$ and $Pr(Z=0)=0.55$. $X$ and $Z$ are independent. ...
6
votes
1answer
1k views

What is the distribution of a sum of identically distributed Bernoulli random varibles if each pair has the same correlation?

What is the distribution of a sum of $n$ Bernoulli random variables, each having success probability $p$, where each pair is correlated with correlation coefficient $\rho$? $$Y = \sum_{i=1}^n X_i$$ $$...
6
votes
1answer
585 views

Proving Bernoulli is the limit of Beta

It's clear to me by inspection that if we fix $\beta = \frac{1-\mu}{\mu} \alpha$ (thereby fixing the mean) and let $\alpha \rightarrow 0$, the Beta distribution approaches a Bernoulli($\mu$) ...
6
votes
1answer
2k views

Zero-inflated Poisson and Gibbs sampling, proofs and sampling

I am trying to figure out zip-inflated Poisson (ZIP) model. In this model, random data $X_1, .., X_n$ are of the form $X_i=R_iY_i$, where the $Y_i$'s have Poisson distribution ($\lambda$) and the $R_i$...
6
votes
1answer
353 views

How can we convert values proportional to probabilities to Bernoulli probabilities?

According to Wikipedia, the parameter in a Bernoulli distribution should be $0<p<1$. I am reading this famous paper proposing Hierarchical Dirichlet Process, and on page 1580, A.6 and the ...
6
votes
1answer
154 views

Is there a name for this process/ distribution?

Does the equation below have a name, or is it similar to some other well-known process/ equation? Equation of interest: $$S_c = S_{c-1} + S_{c-1}\omega_c\delta_c$$ $\delta\sim\mathcal{N}(0,1)$ is a ...
6
votes
2answers
194 views

Finding MLE of $p$ where $X_1\sim\text{Bernoulli}(p)$ and $X_2\sim\text{Bernoulli}(3p)$

Let $X_1\sim\text{Bernoulli}(p)$ and $X_2\sim\text{Bernoulli}(3p)$ be independent Bernoulli random variables where $p\in[0,1/3]$. Derive the MLE of $p$. We have that $$L(p\mid \vec{x})=p^{x_1}(1-...

1
2 3 4 5
11