Friday, January 17, 2014

Fast Food Restaurant Findings

Plan for Data Usage
We gathered a large quantity of data from this restaurant. We took all of this data and found out different trends in certain products. Among the things we found were, the most sold item and the item that generated the most revenue. This information could be useful to this fast food restaurant in the way that they could heavily advertise the products that bring the most revenue, so that the company as a whole can continue to expand. With them being aware of these statistics they could be able to more effectively raise prices in terms that they would be able to increase overall profit. With us having the ability to analyze each menu item that they sell and knowing how many they sell, we create more precise conclusions. For example, we may be able to predict what they will sell more of and make more money off of in the future.

Hypothesis of What We May Be Able to Find
We could use this information to figure out how a new sandwich might do in their industry because of what we have found. We have found that their are a few sandwiches and meals that sell a lot because of their price, and their are a few things that sell purely because they come with something else so are automatically added. Then there are other things that are free to add so those are not really that important.

Information We Discovered
Most fast food restaurants could make a lot of money from selling special sauces, but that probably would not be a good plan, since ranch was a top “selling” item. We also found that pop, generates an enormous amount of revenue. It is one of the top selling items and does not cost the business hardly anything to produce. We found most profitable items to be Drink C, Meal B, Sandwich G and Meal C. We concluded that since these items produce the most amount of revenue, their prices may be increased in the future.

Figure 1: Items Sold With Total Revenue.

We found a confidence interval for the total revenue of all products. We found that we are 95% confident that this fast food restaurant makes between $.84 and $1.46 on every item they sell.

Figure 2: Confidence Interval Items to Revenue.

Dice Football Simulation Game on Python

To start off the second quarter, we wanted to think of project that we would enjoy doing everyday when we went to stats class. After a lot of brainstorming, we came up with an idea. We decided to use a game that my family made a long time ago at my house, called dice football, and try to make it into a simulation game on the computer. We thought this would be a good project for stats class because not only does the game have to do with probability and math, but we can also simulate games hundreds of times to find data, which is what this class is really about.

None of us, Joe, Buster or I, knew anything about the Python Program or how to code. So with the help of Mr. Pethan, and even a little bit from Evan Richardson,  we were able to come up with a series of codes to make our game on the computer. We had to come up with codes to simulate three dice being rolled on offense and two dice being rolled on defense. Depending on what each team rolled, and the play type called by the offense, different outcomes can occur. Just like in regular football, in our game you could score touchdowns or field goals, fumble the ball, or throw an interception. We had to make functions for all of these which took a lot of time and hard work. While working on this project, we also wanted to know which strategy was best for the game (when was the best time to pass, run, or kick a field goal). We decided to create individual "teams" with their own unique functions. For example, one could make a function so they could only run on 3rd down if you had 3 or less yards to go. By making these funcitions, and repeating the results on python, we were able to see patterns of which functions worked better than others. I learned a ton from this project, especially in coding. While I'm still not that great of a coder, I learned the basics needed if I was ever to do something like this again. This project also is great in that it helps you learn how to overcome obstacles. For example, we could take three or four days just to get a function  for runs, pass, kickoffs, or scoring. While we had to be patient, it was worth it in the end to see our game actually work.

If I was to do this project again, the only thing I would do is work on it more and figure out more codes to make the game more specific and fun. For example, we never really made a kickoff or onside function because we never had the time. I would have liked to completely finish the project, but between the modules and our other final project, we never really had the time. Overall, it was a very fun project to work on and it taught me a lot about statistics and the basics of coding. Below are examples of the type of coding we did in Python.