LoslegenKostenlos loslegen

What are the chances of a horse matching or beating Secretariat's record?

Assume that the Belmont winners' times are Normally distributed (with the 1970 and 1973 years removed), what is the probability that the winner of a given Belmont Stakes will run it as fast or faster than Secretariat?

Diese Übung ist Teil des Kurses

Statistical Thinking in Python (Part 1)

Kurs anzeigen

Anleitung zur Übung

  • Take 1,000,000 samples from the normal distribution using the rng.normal() function. The mean mu and standard deviation sigma are already loaded into the namespace of your IPython instance.
  • Compute the fraction of samples that have a time less than or equal to Secretariat's time of 144 seconds.
  • Print the result.

Interaktive Übung

Vervollständige den Beispielcode, um diese Übung erfolgreich abzuschließen.

# Take a million samples out of the Normal distribution: samples


# Compute the fraction that are faster than 144 seconds: prob


# Print the result
print('Probability of besting Secretariat:', prob)
Code bearbeiten und ausführen