# Solved (Free): The amount of protein (in grams) for a variety of fast-food sandwiches is reported here

#### ByDr. Raju Chaudhari

Apr 16, 2021

The amount of protein (in grams) for a variety of fast-food sandwiches is reported here

23  30  20  27  44  26  35  20  20  29
25  15  18  27  19  22  12  26  34  15
27  35  26  43  35  14  24  12  23  31
40  35  38  57  22  42  24  21  27  33

a. Construct a dot plot.
b. Find the proportion fast-food sandwiches with at most 37 grams.
c. Find the proportion of fast-food sandwiches with at least 40 grams.

#### Solution

protein<-c(23,   30, 20, 27, 44, 26, 35, 20, 20,
29, 25, 15, 18, 27, 19, 22, 12, 26, 34, 15, 27,
35, 26, 43, 35, 14, 24, 12, 23, 31, 40, 35, 38,
57, 22, 42, 24, 21, 27, 33)

(a) dotchart of amount of protein

dotchart(protein,xlab="amount of protein")

b. The Proportion fast-food sandwiches with at most 37 grams

most37<-protein[protein<=37]
most37
 [1] 23 30 20 27 26 35 20 20 29 25 15 18 27 19 22 12 26 34 15 27 35 26 35 14 24
[26] 12 23 31 35 22 24 21 27 33
prop37<-length(most37)/length(protein)
prop37
[1] 0.85

Proportion fast-food sandwiches with at most 37 grams is 0.85.

c. The proportion of fast-food sandwiches with at least 40 grams.

least40<-protein[protein>=40]
least40
[1] 44 43 40 57 42
prop40<-length(least40)/length(protein)
prop40
[1] 0.125

Proportion fast-food sandwiches with at least 40 grams is 0.125.