Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please use R to show the whole process of calculation A coffee cart opens at 7 : 0 0 a . m . , and
please use R to show the whole process of calculation
A coffee cart opens at : am and they generally try to prepare a batch large enough to accommodate their customers until : am when the cart closes. The operator only sells oz servings and each serving costs $ to prepare, which includes all costs of production, and any dairysweetener customers may add. Any coffee that isnt sold before : am is considered stale and disposed of for no monetary gain. When purchased, the coffee is poured into a ripple cup, which costs an additional $ per cup. Demand over this period is normally distributed with a mean of and a standard deviation of Each cup retails for $ The cart operator must also purchase a municipal license, which costs a flat $ for the three hours. Assume there are no other costs associated with the cart. Develop a R model with trials that simulates the daily profit resulting from the preparation of and servings of coffee a day.
Write a function that takes as an argument the number of prepared servings in a day and returns a data frame where each row represents a different trial. The returned data frame should include randomly generated numbers for demand. Use these numbers and the information from the problem to calculate the carts total revenue, cost, and profit for each trial as columns in the data frame.
Use the function from part a to determine the carts expected profit if the operator prepares and servings. Which option results in the highest expected profit?
Create a histogram that displays the risk profile of profit for the number of servings with the highest expected profit.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started