首页 > > 详细

辅导留学生Python设计、Python辅导、调试Python

Mock Exam

1. Medical studies have shown that 10 out of 100 adults have heart disease. When a person with
heart disease is given an EKG test, a 0.9 probability exists that the test will be positive. When a
person without heart disease is given an EKG test, a 0.95 probability exists that the test will be
negative. Suppose that a person arrives at an emergency room complaining of chest pains. An
EKG test is given to this person. Use Bayes’ Theorem to answer the following questions. (For
learning purpose, you can also try the JPT approach to answering the following questions)
a. Suppose we randomly select someone and give him or her an EKG test. What is the
probability that this person will be tested positive?
b. If the test is positive, what is the probability that this person actually has heart disease?
c. If the test is negative, what is the probability that this person actually does NOT have heart
disease?
2. In this problem, write ONE line of python code to answer probability-related questions based on
binomial, poission, normal, and exponential distributions. No need to provide the final answer.
Assume that "from scipy.stats import binom, poisson, norm, expon" has already been executed
in Jupyter notebook.

a. According to a 2013 study by the Pew Research Center, 15% of adults in the United States
do not use the Internet. Suppose that 10 adults in the United States are selected randomly.
What is the probability that at least 5 of the adults uses the Internet?
b. Airline passengers arrive randomly and independently at the passenger-screening facility at
a major international airport. The mean arrival rate is 10 passengers per minute. Compute
the probability of no arrivals in a 15-second period.
c. The time needed to complete a final examination in a particular college course is normally
distributed with a mean of 80 minutes and a standard deviation of 10 minutes. What is the
probability that a student will complete the exam in more than 60 minutes but less than 75
minutes?

d. The time between arrivals of vehicles at a particular intersection follows an exponential
probability distribution with a mean of 12 seconds. What is the probability of 30 or more
seconds between vehicle arrivals?
3. In this problem, write ONE line of python code to answer the following questions related on
interval estimation. No need to provide the final answer. Assume that "from scipy.stats import
norm, t" has already been executed in Jupyter notebook.

a. Costs are rising for all kinds of medical care. The mean monthly rent at assisted-living
facilities was reported to have increased 17% over the last five years to $3486. Assume this
cost estimate is based on a sample of 120 facilities and, from past studies, it can be assumed
that the population standard deviation is $650. Develop a 90% confidence interval estimate
of the population mean monthly rent.
b. Based on part a, if the desired margin of error is $50 at a 99% confidence level, what is the
corresponding sample size needed?
c. A sample containing years to maturity and yield for 40 corporate bonds have an average of
9.7 years to maturity and a standard deviation of 5.2 years. Develop a 95% confidence
interval for the population mean years to maturity.
d. In 16% of 200 homes surveyed with a stay-at-home parent, the father is the stay-at-home
parent. Develop a 96% confidence interval for the population proportion of father being the
stay-at-home parent.
e. Based on part d, what sample size will be needed if the desired margin of error is 3%?

 

联系我们
  • QQ:99515681
  • 邮箱:99515681@qq.com
  • 工作时间:8:00-21:00
  • 微信:codinghelp
热点标签

联系我们 - QQ: 99515681 微信:codinghelp
程序辅导网!