# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     language: python
#     name: python3
# ---

# ### Probability, Odds, and  Odds ratios

# **Probability:** the number of ways that an event can occur divided by the total number of possible outcomes. 
#
# The probability of drawing a red card from a standard deck of cards is 26/52 (50 percent). 
# The probability of drawing a club from that deck is 13/52 (25 percent)

# #### What's the probability of getting heads in a fair coin flip? 

# 1/2

# The odds for an event is the ratio of the number of ways the event can occur compared to the number of ways it does not occur.
#
# For example, using the same events as above, the odds for:
# drawing a red card from a standard deck of cards is 1:1; and
# drawing a club from that deck is 1:3.

# #### What's the odds of a fair coin flip?

# 1:1

# #### Suppose that 18 out of 20 patients in an experiment lost weight while using diet A, while 16 out of 20  lost weight using diet B.  

# #### What's the probability of weight loss with diet A? What's the odds?

# **probability**: 18/20 = 9/10
#
# **odds**: 18:2 = 9:1

# #### What's the probablity of weight loss with diet B? What's the odds?

# **probability**: 16/20 = 4/5
#
# **odds**: 16:4 = 4:1

# #### What's the odds ratio?




StarcoderdataJupyterScriptsDedupFiltered