Could you help me how I can solve run this code in R-labUnions

1-You are picking flowers from a garden. The garden contains flowers of

varying colors, including flowers that are completely blue, flowers that

are completely pink, and also flowers that are both colours. The

probability of picking a flower that is at least partly blue is 0.4 and the

probability of picking a flower that is at least partly pink is 0.2. Let's

think about some probabilities!

# Calculate the probability of picking a flower that is blue, pink or both

2-

Conditional Probability I

Enter plants into your console to see information about whether 90 plants

live indoors or outdoors, and whether they are a flower, a succulent or a

tree. The values in this table represent probabilities, calculated from

frequencies.

Let's use these probability values to find some conditional probabilities.

To do this you need to use the formula P(A|B)=P(A+B)/P(B)P(A|B)=P(A+B)/P(B).

# What is the probability a plant lives indoors?

# What is the probability a plant is a flower, given that we know it lives

indoors?

# What is the probability a plant lives indoors, given that we know it is a

succulent?

-------------------------------------------------------------------------

*Sadia seddiqi*

*Health Care Financing Officer *

*Health Economics & Financing Directorate (HEFD) Ministry of Public Health

(MoPH), Kabul-Afghanistan*

* Email:

[hidden email] <

[hidden email]>

<+93%2078%20692%207270>*

[[alternative HTML version deleted]]

______________________________________________

[hidden email] mailing list -- To UNSUBSCRIBE and more, see

https://stat.ethz.ch/mailman/listinfo/r-helpPLEASE do read the posting guide

http://www.R-project.org/posting-guide.htmland provide commented, minimal, self-contained, reproducible code.