Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

MRJob in Python In this assignment, you are going to compute the best three stocks listed in the Dow Jones index based on the first

MRJob in Python

image text in transcribed

In this assignment, you are going to compute the best three stocks listed in the Dow Jones index based on the first two quarters in 2011. The data look like the following where the columns are quarter, stock_label, date, opening_price, day_high, day_low, closing_price, and traded_volume. The stock performance should be based on the closing price. The percentage of gain is computed as price-at-the-last-date - price-at-the-first-date/price-at-the-first-date * 100 To test the code, name your program Statistics.py and run the following command NestedGreaterGreater python Statistics.py dow_jones_index.csv > output.txt The expected results should look like the following where the columns are stock_label, percentage_of_gain, and average_traded_volume ('IBM', '11.59%', '24739184.44') ('KRFT', '10.93%', '44816171.24') ('MCD', '10.04%', '32151700.28') In this assignment, you may need more than just one mapper and reducer

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

Assume you are a real estate broker with an exclusive contract

Answered: 1 week ago

Question

5. Do you have any foreign language proficiency?

Answered: 1 week ago