1. A mechanical engineer is analyzing tensile strength of steel ( API 5L X65). A sample of 7 specimens showed a sample mean of 530 M P a. The standard deviation is known to be σ = 5 M P a. A 95% upper confidence interval for the true mean tensile strength is:
2. The Z critical value that should be used in order to create a 95% lower confidence interval is:
3: For an automated bottle filling, a 95% upper confidence interval of fill volume is ( 489 , ∞ ) milliliters. How could you best describe the confidence interval?
- The true mean fill volume is less than or equal to 489 milliliters for 95% of the bottles
-The true mean fill volume is greater than or equal to 489 milliliters for 95% of the bottles
-The true mean fill volume is greater than or equal to 489 milliliters for 5% of the bottles
4. The pH value of 5 water samples taken from a small lake follow: 7.3, 7.6, 7.2, 7.9, and 7.8. The true standard deviation of water of the lake is unknown. A 95% upper confidence interval for the pH is:
5. You need to test if the water in the small lake described in question (04) is basic, i.e. if the pH is significantly greater than 7.0. The correct form of the Null and Alternative hypotheses are:
6. This question is worth 2 points: A manufacturer produces piston rings for an automobile engine. It is known that ring diameter is Normally Distributed with σ = 0.001 millimeters. A random sample of 15 rings has a mean diameter of 74.036 millimeters. Test if the true mean ring diameter is significantly greater than 74.035 millimeters. Select the correct interpretation of the test result:
- We have NO statistical evidence with 95% probability to conclude that the true mean ring diameter is significantly greater than 74.035 millimeters.
-We have statistical evidence with 95% probability to conclude that the true mean ring diameter is significantly greater than 74.035 millimeters.
-We have NO statistical evidence with 95% probability to conclude that the true mean ring diameter is significantly equal to 74.035 millimeters.
7.A machine produces metal rods used in an automobile suspension system. A random sample of 15 was selected, and the diameter is measured. The sample mean diameter was found to be 8.24 millimeters. The true standard deviation of the diameters is maintained at σ = 0.02 millimeters. You test if the true mean diameter is significantly lesser than 8.25 millimeters. The P value of the test should be:
8. You need to test: H 0 ; μ = 25 v s H 1 ; μ > 25 . The P value of the test was found to be 0.094. A possible upper 95% confidence interval for μ is:
9. You need to test H 0 ; μ = 50 v s H 1 ; μ > 50. The Z test statistic is found to be 2.03. The P value of the test should be:
In: Statistics and Probability
QUESTION 1
Suppose you manage an algorithmic trading operation where computers are trading in the stock market automatically without human intervention using algorithms. Suppose that your algorithm called “Shining Star” (SS) makes an average profit of $6000 each trading hour in the stock market. However, your gut instinct is that the algorithm’s performance has decreased recently. We have provided a random sample of 75 of the more recent hours of trading performance.
PARTS
Write down a hypothesis test for checking if the performance has
decreased. Suppose your significance level is 0.01 .
a) Write down the test statistic.
b) What is the name of the model/distribution that would be
appropriate to use for the probability distribution of the test
statistic? Also, please state your assumptions for picking that
distribution.
c) Please provide as much information as you can about the relevant
parameters for the distribution (e.g., mean and standard deviation)
under the status quo or null.
a) What is your p-value for this test?
b) What is the critical threshold for your test statistic?
b) Has the performance of your SS algorithm decreased? Why or why
not?
[
a) Now write down a hypothesis test for checking if the performance
has increased. Suppose your significance level is 0.01 .
b) What is your p-value for this test?
c) Has the performance of your SS algorithm increased? Why or why
not?
QUESTION 2
Internet retailers have so much data! Epods.com
finds that there is a 10% chance that a visitor buys a product.
Using sales data over the past two years, you’ve helped them
realize that if a visitor spends a long amount of time on the site
(i.e., more than 5 minutes), it effects the probability of the
visitor buying a product. In particular, among all the buys made by
visitors, 80% of time the visitor spent a large amount of time on
the site. Among all the visits that resulted in no buy or purchase,
25% of the time the visitor spent a large amount of time on the
site.
For all the parts below, if there is a formula involved, please
show your work or the relevant formula using probabilistic
notation, e.g., P( something1 | something2 ) = … .
Hint:
Define the events
B = visitor buys a product
L = visitor spends a long amount of time on the site (i.e., more
than 5 minutes)
What is the prior probability of a visitor buying a product?
What is the conditional probability of a visitor spending a long amount of time on the site, given that the visitor makes a purchase?
What is the conditional probability that a visitor buys a product given that the visitor spends a long amount of time on the site?
What is the conditional probability that a visitor does not make a purchase given that the visitor has spent a long time on the site?
What is the conditional probability that a visitor makes a purchase given that the visitor does not spend a long time on the site?
QUESTION 3 and QUESTION 4: Context
Suppose you are part of the analytics team for the online retailer Macha Bucks which sells two types of tea to its online visitors: Rouge Roma (RR) and Emerald Earl (EE). Everyday approximately 10,000 people visit the site over a 24 hour period. For simplicity suppose we consider the “buy one or don’t buy” (BODB) market segment of customers which when they visit the site will conduct one of the following actions: (a) buy one order of RR, (b) buy one order of EE, or (c) don’t buy (DB) anything. You have been tasked with determining customer behavior on the website for the BODB segment using a random sample of 35 visits.
In the dataset for the random sample, each row corresponds to a random visitor. For each visitor we provide both the visitor’s action as well as the profit earned on the transaction. In the action column:
if the visitor buys one order of RR, we see a RR,
if the visitor buys one order of EE, we see an EE,
if the visitor doesn’t buy anything, we see a DB.
Note that even if two customers buy the same product, the profit can differ due to the shipping costs, promotions, or coupons that are applied.
QUESTION 3
PARTS
Using the sample data, obtain a point estimate for the proportion
of customers in this BODB market segment that
a) purchase EE:
b) purchase RR:
c) don’t buy:
a) What is the name of the model/distribution that would be
appropriate to use for the probability distribution of the sample
proportion of the BODB market segment that purchases EE?
b) Please provide as much information as you can about the relevant
parameters for the distribution (e.g., mean and standard
deviation).
Please provide a 95% confidence interval for population proportion
of the BODB market segment that
a) purchase EE:
b) purchase RR:
c) don’t buy:
a) What does the 95% confidence interval mean intuitively? Please
provide an interpretation.
b) What could you do to obtain a narrower 95% confidence
interval?
c) What would you need to do to have a margin of error of 0.05?
Please do the calculation.
a) Please provide a 99% confidence interval for the population
proportion of the BODB market segment that purchases EE.
b) When would you prefer a 99% confidence interval rather than a
95% confidence interval?
What is the 95% confidence interval for the average profit from
a
a) EE customer (i.e., a customer in the BODB market segment that
buys EE):
b) RR customer (i.e., a customer in the BODB market segment that
buys RR):
c) Clearly state any assumptions you make about the sampling
distribution.
QUESTION 4
PARTS
a) What could be an appropriate probability distribution to use for
modeling the number of visitors that the website has in an
hour?
b) What parameters would you use for the probability
distribution?
c) Using that distribution, determine the probability that more
than 600 people visit the site in an hour.
a) What could be an appropriate probability distribution to use for
modeling the number of seconds between customer visits?
b) What parameters would you use for the probability
distribution?
c) Using that distribution, determine the probability that the time
between customer visits to the website is less than 10 seconds.
a) What could be an appropriate probability distribution to use for
modeling the number of website visitors from 100 visitors that do
not buy anything?
b) What parameters would you use for the probability
distribution?
c) Using that distribution, determine the probability that from
among 100 customers, it turns out that 30 or more customers do not
buy anything.
d) What is the average number of visitors (from among 100
customers) that do not buy anything?
e) What is the standard deviation of the number of visitors (from among 100 customers) that do not buy anything?
What is the average profit from among 100 random customers that
visit the site?
Please explain your answer or show your calculations.
In: Statistics and Probability
In: Psychology
i am looking to add more detail into my program the runs a game of rock paper scissors
i want to include a function or way to ask the user to input their name so that it could be shown in the results at the end of a round/game.
after a round something like "Mike wins!"
i also want to output the round number when the result of for each round is outputed
Round 1: Mike Wins!
Round 2: Computer wins!
#include <iostream>
#include <iomanip>
#include <cstdlib>
#include <vector>
#include <ctime>
using namespace std;
int getCpu();
int getComputerChoice();
int getPlayerChoice();
bool isTie(int, int);
bool isPlayerWinner(int, int);
int menu();
void runGame();
int main()
{
runGame();
return 0;
}
void runGame()
{
int userChoice;
int playerChoice;
int computerChoice;
int rounds;
vector <string> winner;
do
{
winner.clear();
userChoice = menu();
if (userChoice == 1)
{
do
{
cout<<"\n Enter how many rounds to play? ";
cin>>rounds;
if(rounds % 2 == 0)
break;
else
cout<<"\n Enter a even number of rounds. \t Try
again!!";
}while(1);
for(int c = 0; c < rounds; c++)
{
playerChoice = getPlayerChoice();
computerChoice = getComputerChoice();
if (isTie(playerChoice, computerChoice))
cout << "It's a TIE!\n\n";
else if (!isPlayerWinner(playerChoice, computerChoice))
{
cout << "Sorry you LOSE.\n\n";
winner.push_back("Computer WIN!");
}
else if (isPlayerWinner(playerChoice, computerChoice))
{
winner.push_back("Player WIN!");
cout << "You WIN!\n\n";
}
}
cout<<"\n ********** Final Result (Player vs. Computer)
********** ";
for(int c = 0; c < winner.size(); c++)
cout<<"\n"<<winner[c];
}
else if (userChoice == 2)
{
do
{
cout<<"\n Enter how many rounds to play? ";
cin>>rounds;
if(rounds % 2 == 0)
break;
else
cout<<"\n Enter a even number of rounds. \t Try
again!!";
}while(1);
for(int c = 0; c < rounds; c++)
{
playerChoice = getCpu();
computerChoice = getComputerChoice();
if (isTie(playerChoice, computerChoice))
cout << "It's a TIE!\n\n";
else if (!isPlayerWinner(playerChoice, computerChoice))
{
cout << "Player 2 WIN!\n\n";
winner.push_back("Player 2 WIN!");
}
else if (isPlayerWinner(playerChoice, computerChoice))
{
cout << "Player 1WIN!\n\n";
winner.push_back("Player 1 WIN!");
}
}
cout<<"\n ********** Final Result (Computer vs. Computer)
********** ";
for(int c = 0; c < winner.size(); c++)
cout<<"\n"<<winner[c];
}
else if(userChoice == 3)
exit(0);
else
cout << "Invalid selection. Try again.\n\n";
}while(1);
}
int menu()
{
int userChoice;
cout << "\n\n Welcome to rock paper scissors" <<
endl;
cout <<"Please select a game mode" << endl;
cout << "1. Player vs. Computer" << endl;
cout << "2. Computer vs. Computer" << endl;
cout << "3. Exit" << endl;
cin >> userChoice;
return userChoice;
}
int getComputerChoice()
{
srand(time(NULL));
int randomCompNum = rand() % 3 + 1;
if (randomCompNum == 1)
{
cout << "The computer chose : Rock\n\n";
}
else if (randomCompNum == 2)
{
cout << "The computer chose : Paper\n\n";
}
else if (randomCompNum == 3)
{
cout << "The computer chose : Scissors\n\n";
}
return randomCompNum;
}
int getCpu()
{
srand(time(NULL));
int cpu = rand() % 6;
if (cpu == 1 || cpu == 4)
{
cout << "player 1 chose : Rock\n\n";
}
else if (cpu == 2 || cpu == 5)
{
cout << "player 1 chose : Paper\n\n";
}
else if (cpu == 3 || cpu == 6)
{
cout << "player 1 chose : Scissors\n\n";
}
return cpu;
}
int getPlayerChoice()
{
int myChoice;
cout<< "\n\nRock, Paper, or Scissors?\n"
<< "1) Rock\n"
<< "2) Paper\n"
<< "3) Scissors\n"
<< "Please enter your choice : \n";
cin >> myChoice;
if (myChoice == 1)
{
cout << "\nYou chose : Rock\n";
}
else if (myChoice == 2)
{
cout << "\nYou chose : Paper\n";
}
else if (myChoice == 3)
{
cout << "\nYou chose : Scissors\n";
}
return myChoice;
while (myChoice < 1 || myChoice > 3)
{
cout << "Please pick a number between 1 & 3.\n";
cin >> myChoice;
}
}
bool isPlayerWinner(int myChoice, int randomCompNum)
{
if (((myChoice == 1) && (randomCompNum == 3)) || ((myChoice
== 3) && (randomCompNum == 2)) ||
((myChoice == 2) && (randomCompNum == 1)))
{
return true;
}
else if (((randomCompNum == 3) && (myChoice == 1)) ||
((randomCompNum == 3) && (myChoice == 2)) ||
((randomCompNum == 2) && (myChoice == 1)))
{
return false;
}
return 0;
}
bool isTie(int myChoice, int randomCompNum)
{
if (myChoice == randomCompNum)
{
return true;
}
else if (myChoice != randomCompNum)
{
return false;
}
return 0;
}
In: Computer Science
|
Stocks A and B have the following probability distributions of expected future returns:
|
In: Finance
Stocks A and B have the following probability distributions of expected future returns:
| Probability | A | B |
| 0.3 | (15%) | (30%) |
| 0.2 | 3 | 0 |
| 0.2 | 11 | 20 |
| 0.1 | 24 | 26 |
| 0.2 | 33 | 40 |
Calculate the expected rate of return, , for Stock B ( = 7.30%.)
Do not round intermediate calculations. Round your answer to two
decimal places.
%
Calculate the standard deviation of expected returns,
σA, for Stock A (σB = 26.58%.) Do not round
intermediate calculations. Round your answer to two decimal
places.
%
Now calculate the coefficient of variation for Stock B. Round your answer to two decimal places.
Is it possible that most investors might regard Stock B as being less risky than Stock A?
Assume the risk-free rate is 2.5%. What are the Sharpe ratios for Stocks A and B? Do not round intermediate calculations. Round your answers to two decimal places.
Stock A:
Stock B:
Are these calculations consistent with the information obtained from the coefficient of variation calculations in Part b?
In: Finance
Stock AAA has the following probability distribution: If economy is good (the probability is 30%), its expected stock return is 30%; if economy is on average (the probability is 40%), its expected stock return is 10%; if economy is bad (the probability is 30%), its expected return is -10%. Find the expected rate of return for stock AAA
|
4.0% |
||
|
6.0% |
||
|
10.0% |
||
|
14.0% |
Using the data from above, find the standard deviation (risk) for stock AAA
|
13.49% |
||
|
14.59% |
||
|
15.49% |
||
|
16.56% |
Using the results from Question 34 and 35, calculate the coefficient of variation for stock AAA
|
1.55 |
||
|
1.78 |
||
|
1.99 |
||
|
0.65 |
In: Finance
Stocks A and B have the following probability distributions of expected future returns:
| Probability | A | B | ||
| 0.1 | (9 | %) | (30 | %) |
| 0.2 | 6 | 0 | ||
| 0.5 | 12 | 22 | ||
| 0.1 | 21 | 26 | ||
| 0.1 | 32 | 47 | ||
%
%
Now calculate the coefficient of variation for Stock B. Do not round intermediate calculations. Round your answer to two decimal places.
Is it possible that most investors might regard Stock B as being less risky than Stock A?
-Select-IIIIIIIVVItem 4
Assume the risk-free rate is 2.5%. What are the Sharpe ratios for Stocks A and B? Do not round intermediate calculations. Round your answers to four decimal places.
Stock A:
Stock B:
Are these calculations consistent with the information obtained from the coefficient of variation calculations in Part b?
-Select-IIIIIIIVV
In: Finance
Stocks A and B have the following probability distributions of expected future returns:
| Probability | A | B | ||
| 0.1 | (7 | %) | (35 | %) |
| 0.2 | 3 | 0 | ||
| 0.5 | 13 | 18 | ||
| 0.1 | 20 | 25 | ||
| 0.1 | 29 | 44 | ||
%
%
Now calculate the coefficient of variation for Stock B. Do not round intermediate calculations. Round your answer to two decimal places.
Is it possible that most investors might regard Stock B as being less risky than Stock A?
-Select-IIIIIIIVVItem 4
Assume the risk-free rate is 1.5%. What are the Sharpe ratios for Stocks A and B? Do not round intermediate calculations. Round your answers to four decimal places.
Stock A:
Stock B:
Are these calculations consistent with the information obtained from the coefficient of variation calculations in Part b?
In: Finance
Stocks A and B have the following probability distributions of expected future returns:
| Probability | A | B | ||
| 0.1 | (9 | %) | (33 | %) |
| 0.1 | 5 | 0 | ||
| 0.6 | 12 | 23 | ||
| 0.1 | 20 | 27 | ||
| 0.1 | 38 | 45 | ||
%
%
Now calculate the coefficient of variation for Stock B. Do not round intermediate calculations. Round your answer to two decimal places.
Is it possible that most investors might regard Stock B as being less risky than Stock A?
Assume the risk-free rate is 3.5%. What are the Sharpe ratios for Stocks A and B? Do not round intermediate calculations. Round your answers to four decimal places.
Stock A:
Stock B:
Are these calculations consistent with the information obtained from the coefficient of variation calculations in Part b?
In: Finance