##
Formula-Based Basic Statistics Questions in New Quizzes

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Canvas has a limited set of functions it provides for use in formula questions. James has already written Blog posts with some work-arounds. Below, I give concrete examples of Canvas New Quizzes formula questions for hypothesis testing and confidence intervals expanding on James's ideas using known approximations to the normal distribution, inverse normal distribution, and t-distribution. Approximations are good only to about 2-3 decimal places.

**Example of a standard normal distribution question: **

Dinners at four star restaurants in a certain city cost on average $`X` with a standard deviation of $`S` and are normally distributed. You go out to eat at random at these restaurants `n` times. What is the probability that the average you spend is greater than $50? Round your answer to two decimal places.

**Variables: **

Variable | Min | Max | Decimals |

S | 10 | 20 | 0 |

X | 44 | 49 | 0 |

n | 10 | 20 | 0 |

**Formula Definition:**

a = (50 -X)/(S/sqrt(n))

cdf = if(a,if(a + abs(a),

1-(0.31938153/(1+0.2316419*a)-0.356563782/(1+0.2316419*a)^2+

1.781477937/(1+0.2316419*a)^3-1.821255978/(1+0.2316419*a)^4+

1.330274429/(1+0.2316419*a)^5)*e^(-0.5*a^2)/sqrt(2*pi),

(0.31938153/(1-0.2316419*a)-0.356563782/(1-0.2316419*a)^2+

1.781477937/(1-0.2316419*a)^3-1.821255978/(1-0.2316419*a)^4+

1.330274429/(1-0.2316419*a)^5)*e^(-0.5*a^2)/sqrt(2*pi)),

0.5)

1-cdf

**Generate Possible Solutions: **

Number of solutions: 200. Decimal Places: 4. Margin type: absolute. +/- margin of error: 0.005.

**Example of an inverse standard normal distribution question: **

Suppose that weights in pounds of bags of flour follow a normal distribution with a standard deviation of 0.5 lbs. If `PP`% of bags are heavier than `x` lbs, what is the mean of this distribution? Round to two decimal places.

**Variables: **

Variable | Min | Max | Decimals |

PP | 1 | 10 | 0 |

x | 100 | 125 | 0 |

**Formula Definition:**

P = PP/100

R = if( (P - 0.5) + abs(P - 0.5), 1-P, P)

Y = sqrt(-2*ln(R))

Z= if((R - 0.5), if( (P - 0.5) + abs(P - 0.5), Y - ((((0.0000453642210148*Y + 0.0204231210245)*Y + 0.342242088547)*Y+1)*Y + 0.322232431088) / ((((0.0038560700634*Y + 0.10353775285)*Y+0.531103462366)*Y +0.588581570495)*Y + 0.099348462606),((((0.0000453642210148*Y + 0.0204231210245)*Y + 0.342242088547)*Y+1)*Y + 0.322232431088) / ((((0.0038560700634*Y + 0.10353775285)*Y+0.531103462366)*Y +0.588581570495)*Y + 0.099348462606) -Y ), 0)

x + 0.5*Z

**Generate Possible Solutions: **

Number of solutions: 200. Decimal Places: 6. Margin type: absolute. +/- margin of error: 0.005.

**Example of a t-distribution question: **

Find the probability that a T-distribution with `nu` degrees of freedom is less than `z`. Round your answer to two decimal places.

**Variables: **

Variable | Min | Max | Decimals |

nu | 5 | 25 | 0 |

z | -3.00 | 3.00 | 2 |

**Formula Definition:**

T = abs(z)

tanh(x) = (e^(2*x) -1)/(e^(2*x) + 1)

x=-0.06148*nu + 0.011443*T + 0.841444

H14 = tanh(x)

x = -0.011259*nu - 0.31433*T + 1.125778

H13 =tanh(x)

x = 0.219778*nu - 0.212474*T + 0.776667

H12 = tanh(x)

x = 0.015481*nu - 0.268557*T + 0.22856

H11 = tanh(x)

x = -0.726 + 1.769*H11 - 1.304*H12 + 0.284*H13 + 0.78*H14

H24 = tanh(x)

x = -1.545 + 1.796*H11- 0.115*H12 + 0.918*H13 + 0.701*H14

H23 = tanh(x)

x = 0.936 - 0.613*H11 + 1.339*H12 - 1.148*H13 - 0.796*H14

H22 = tanh(x)

x = -2.013 + 1.718*H11 - 0.043*H12 + 1.346*H13 + 0.39*H14

H21 = tanh(x)

y = 0.259 - 1.435*H21 + 0.604*H22 + 0.548*H23 + 0.75*H24

if(z, if(z + abs(z), y, 1-y), 0.5)

**Generate Possible Solutions: **

Number of solutions: 200. Decimal Places: 4. Margin type: absolute. +/- margin of error: 0.005.

These formulas came from James's blog post, the Odeh and Evans formula in

https://link.springer.com/content/pdf/10.3758/BF03200956.pdf, and the approximation for the T Distribution in https://statperson.com/Journal/StatisticsAndMathematics/Article/Volume8Issue1/IJSAM_8_1_4.pdf

Drawing on James's list idea for a class that uses Excel for the exams, the following uses the list feature to "look up" the relevant t-distribution value.

**Example of a one-sample confidence interval question:**

Find the lower limit of a `PP`% confidence interval for the mean number of calories in a McDonald's Big Mac given the sample values from 10 random Big Macs provided in the table below. Round your answer to two decimal places.

Calories in the sampled Big Mac |

`x1` |

`x2` |

`x3` |

`x4` |

`x5` |

`x6` |

`x7` |

`x8` |

**Variables: **

Variable | Min | Max | Decimals |

PP | 96 | 99 | 0 |

x1 | 575 | 650 | 0 |

x2 | 575 | 650 | 0 |

x3 | 575 | 650 | 0 |

x4 | 575 | 650 | 0 |

x5 | 575 | 650 | 0 |

x6 | 575 | 650 | 0 |

x7 | 575 | 650 | 0 |

x8 | 575 | 650 | 0 |

**Formula Definition:**

xbar = mean(x1, x2, x3, x4, x5, x6, x7, x8)

sumsq= sum((x1 - xbar)^2, (x2 - xbar)^2, (x3 - xbar)^2, (x4 - xbar)^2, (x5 - xbar)^2, (x6 - xbar)^2, (x7 - xbar)^2, (x8 - xbar)^2)

s = sqrt(sumsq/7)

tarray = reverse(reverse(3.499483297, 2.997951567, 2.714573011, 2.516752424))

entry = (99-PP)

xbar - (s/sqrt(8))*at(tarray, entry)

**Generate Possible Solutions: **

Number of solutions: 200. Decimal Places: 3. Margin type: absolute. +/- margin of error: 0.005.