Question: Assignment Overview This assignment will give you some experience solving a somewhat unstructured problem. Background Former President Bill Clinton said in his speech to the

Assignment Overview This assignment will give you some experience solving a somewhat unstructured problem.

Background Former President Bill Clinton said in his speech to the Democratic National Convention in Charlotte:

"Since 1961, for 52 years now, the Republicans have held the White House 28 years, the Democrats 24. In those 52 years, our private economy has produced 66 million private-sector jobs. So what's the jobs score? Republicans 24 million, Democrats 42 (million)."

In the packed convention hall, it was one of the nights biggest applause lines.

Did he have his facts right? Lets check.

Program Specifications Weve done a lot of initial work for you and provided the file BLS_private.csv. Data in the file are in thousands (as noted in the file). Where does this file come from? A little research shows that Clinton probably got his data from an article on bloomberg.com (http://www.bloomberg.com/news/2012-0508/private-jobs-increase-more-with-democrats-in-white-house.html) which got their data from the Bureau of Labor Statistics (bls.gov) at the U.S. Department of Laborthe definitive, non-partisan source of jobs data. In the quote above you can see that he refers to private employment data (presumably seasonally adjusted). The data can be found at http://data.bls.gov/cgibin/surveymost?ce if you check the box Total Private Employment. You then need to select the years starting in 1961. The result is an MS Excel file that can be saved in comma-separated values format (csv). (If you are mistrustful, as you should be, you could check that we are providing the correct data.)

You need data on the presidents in that time period so you must create an input file named presidents.txt for that purpose. You will have to research the presidents to gather data for this file. What data do you need? That is part of your task: you need the data so you can check Clintons statement, so figure it out. Also, an additional constraint is that your presidents.txt file cannot have any jobs data in itall jobs data must come from the BLS_private.csv file. Your presidents.txt file will simply be a file of words and numbers that you can create using something like Notepad (Windows) or TextEdit (Mac).

Your task is to combine the input from both files (our BLS_private.csv and your presidents.txt) to see if you can verify Clintons statement. You have a number of challenges such as: what does he mean by produced?

What output is expected? We dont specify that either. You need sufficient output to show that you have verified (or not) Clintons assertion. Simply saying verified (or not) is not sufficient: justify your assertion.

Since part of your task is to convince the instructor that you have in fact verified (or not) Clintons assertion you will need to make sure that what you are trying to do in your code is understandable, i.e. take care with your comments that they will help the reader understand what you are doing.

Assignment Notes 1. The BLS csv data file is quite clean so you do not need to use the csv module to read the file. However, feel free to use it if you wantit can be a useful tool for messy csv files. 2. A good place to start is to read in the csv file and print it out. Then collect some job data and add it up; for example: January data. 3. We dont tell you which data structures you should use: you choose. (However, we do not expect you to use classes.) 4. A clue to the numbers comes from this quote from politifact.com (but dont expect your numbers to match exactly since they dont precisely state their source): (http://www.politifact.com/truth-o-meter/statements/2012/sep/06/bill-clinton/bill-clinton-saysdemocratic-presidents-top-republ/)

Lets cut to the chase. According to the Bureau of Labor Statistics, here are the net increases in private-sector employment under each president, chronologically by party:

Republicans

Richard Nixon: Increase of 7.1 million jobs Gerald Ford: Increase of 1.3 million jobs Ronald Reagan: Increase of 14.7 million jobs George H.W. Bush: Increase of 1.5 million jobs George W. Bush: Decline of 646,000 jobs

Total: Increase of 23.9 million jobs under Republican presidents

Democrats

John F. Kennedy: Increase of 2.7 million jobs Lyndon B. Johnson: Increase of 9.5 million jobs Jimmy Carter: Increase of 9.0 million jobs Bill Clinton: Increase of 20.8 million jobs Barack Obama: Increase of 332,000 jobs

Total: Increase of 42.3 million jobs. So Clinton is right. 5. Note that two presidents didnt complete their terms and that tweaks the numbers a bit. A better result will work that in. 6. The actual program is quite smallthe challenge is figuring out what needs to be done.

Something to think about: Mark Twain observed: There are three kinds of lies: lies, lies, and statistics. Simply having correct data doesnt mean that you are telling the correct story, and that could apply to Clintons quote. In what ways is this the wrong data? How could the numbers be adjusted to better reflect the influence that a president has on this data?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!