2
$\begingroup$

I am trying to calculate P(x>=3) using R. What I wrote is the following;

ppois(3,4.5) #this returns 0.342296

the problem here is that the value is for (Px<=3). I know that including "lower = FALSE" will return P(X>3)

ppois(3,4.5,lower=FALSE) #This returns 0.657704 which is P(X>3)

What would I have to modify or include to return P(X>=3)?

$\endgroup$
0

1 Answer 1

7
$\begingroup$

Note that $ P(X \ge 3)$ is equivalent to $P(X > 2)$

We can then calculate the following probability as follow: \begin{equation} P(X > 2) = 1-P(X \le 2) = 0.8264 \end{equation}

We can then compute the desired probability using R:

# P(X>2)
ppois(2,4.5, FALSE)

#OR

# 1-P(X<=2)
1-ppois(2,4.5)

Output:

0.8264219

As a side note - RStudio is a R Integrated Development Environment (IDE)

$\endgroup$
1
  • $\begingroup$ there is also the argument lower.tail=FALSE to ppois to save you the 1 - part. $\endgroup$
    – JDL
    Nov 5, 2020 at 12:04

Not the answer you're looking for? Browse other questions tagged or ask your own question.