Azhar Kudaibergenova
2022-11-14
(BAC) is a commonly used measure of alcohol intoxication, also known as drunkenness. It is typically expressed as a percentage of alcohol per volume of blood. For example, in the United States (US), a BAC of 0.08 (0.08%) would translate to 0.08 grams of alcohol per 100 mL of blood.
In the US, the legal limit for BAC when driving is 0.08%. Drivers who are over the age of 21 (the legal drinking age in the US), who have a BAC equal to or greater than 0.08%, can face penalties. Penalties for those under the age of 21 are stricter, but vary by state. For those under the age of 21, the legal limit ranges from 0.01% to 0.05%.
BAC = [Alcohol consumed in grams/ (Body weight in grams * R)]* 100
Factors in this equation
R = Gender - a constant .55 for Females .68 for Males Grams of Alcohol Consumed (Number of drinks x 14) Body weight in pounds x 454 = bodyweight in grams
MenDrunk = MenBAC %>% mutate(BACLevel = case_when(
between(BAC, 0.00, 0.15) ~ "Normal",
between(BAC, 0.151, 0.25) ~ "Slightly Impaired",
between(BAC, 0.26, 0.39) ~ "Mild Impaired",
between(BAC, 0.40, 0.51) ~ "Life Threatening",
TRUE ~ NA_character_
))
table(MenDrunk$BACLevel)##
## Life Threatening Mild Impaired Normal Slightly Impaired
## 2 3 9 6
Keep in mind that everyone metabolizes alcohol at the same rate–.015 an hour. This party lasted 8 hours.
After8 = MenDrunk %>% mutate(BAC8 = BAC - (8 * 0.015))
After8M = After8 %>% mutate(BACLevel = case_when(
between(BAC8, 0.00, 0.15) ~ "Normal",
between(BAC8, 0.151, 0.25) ~ "Slightly Impaired",
between(BAC8, 0.26, 0.39) ~ "Mild Impaired",
between(BAC8, 0.40, 0.51) ~ "Life Threatening",
TRUE ~ NA_character_
))
table(After8M$BACLevel)##
## Mild Impaired Normal Slightly Impaired
## 2 11 3
Calculate by Type of drink Number of oz * % of Alcohol * 0.789 = Grams of alcohol Consumed Grams of Alcohol / Weight in pounds
Let’s Calculate by type of Alcohol
WomenL = subset(Total, Sex == "F")
WomenL = WomenL %>% mutate(Level = case_when(
between(BAC, 0.00, 0.0149) ~ "Normal",
between(BAC, 0.015, 0.021) ~ "Slightly Impaired",
between(BAC, 0.022, 0.029) ~ "Mild Impaired",
between(BAC, 0.03, 0.051) ~ "Life Threatening",
TRUE ~ NA_character_
))
table(WomenL$Level)##
## Life Threatening Mild Impaired Normal Slightly Impaired
## 2 1 5 6
MenL = subset(Total, Sex == "M")
MenL = MenL %>% mutate(Level = case_when(
between(BAC, 0.00, 0.0157) ~ "Normal",
between(BAC, 0.0158, 0.0189) ~ "Slightly Impaired",
between(BAC, 0.019, 0.029) ~ "Mild Impaired",
between(BAC, 0.03, 0.051) ~ "Life Threatening",
TRUE ~ NA_character_
))
table(MenL$Level)##
## Life Threatening Mild Impaired Normal Slightly Impaired
## 3 5 9 3
ggplot(TotalLevel, aes(fill = Sex, x = BAC, y = Level))+
geom_bar(position = "stack", stat = "identity")