Design java application that will read file containing data

Assignment Help JAVA Programming
Reference no: EM131601402

Final Project

Before attempting this project, be sure you have completed all of the reading assignments, hands-on labs, discussions, and assignments to date.

1. Design a Java application that will read a file containing data related to the US. Crime statistics from 1994-2013. The description of the file is shown below. The application should provide statistical results on the data including:

a. Population growth in percentages from each consecutive year (e.g. 1994-1995 calculation is ((262803276 - 260327021)/260327021)*100 = 0.9512%, 1995-1996 would be ((265228572 - 262803276)/262803276)*100 = 0.9229%)
b. Years where the maximum and minimum Murder rates occurred.
c. Years where the maximum and minimum Robbery rates occurred.
d. Total percentage change in Motor Vehicle Theft between the years 1998 and 2012.
e. Two (2) additional crime statistics results you add to enhance the application functionality.

The following are some design criteria and specific requirements that need to be addressed:

a. Use command line arguments to send in the name of the US Crime Data file.
b. You are not allowed to modify the Crime.csv Statistic data file included in this assignment.
c. Use arrays and Java classes to store the data. (Hint: You can and should create a USCrimeClass to store the fields. You can also have an Array of US Crime Objects.)
d. Your design should include multiple classes to separate the functionality of the application.
e. You should create separate methods for each of the required functionality. (e.g. getMaxMurderYear() will return the Year where the Murder rate was highest. )
f. A user-friendly and well-organized menu should be used for users to select which data to return. A sample menu is shown in run example. You are free to enhance your design and you should add additional menu items and functionality.
g. The menu system should be displayed at the command prompt, and continue to redisplay after results are returned or until Q is selected. If a user enters an invalid menu item, the system should redisplay the menu with a prompt asking them to enter a valid menu selection
h. The application should keep track of the elapsed time (in seconds) between once the application starts and when the user quits the program. After the program is exited, the application should provide a prompt thanking the user for trying the US Crime Statistics program and providing the total time elapsed.

Here is sample run:

java TestUSCrime Crime.csv

********** Welcome to the US Crime Statistical Application ************************** Enter the number of the question you want answered. Enter ‘Q' to quit the program :
1. What were the percentages in population growth for each consecutive year from 1994 - 2013?
2. What year was the Murder rate the highest?
3. What year was the Murder rate the lowest?
4. What year was the Robbery rate the highest?
5. What year was the Robbery rate the lowest?
6. What was the total percentage change in Motor Vehicle Theft between 1998 and 2012?
7. What was [enter your first unique statistic here]?
8. What was [enter your second unique statistic here]?
Q. Quit the program

Enter your selection: 2

The Murder rate was highest in 1994

Enter the number of the question you want answered. Enter ‘Q' to quit the program :

1. What were the percentages in population growth for each consecutive year from 1994 - 2013?
2. What year was the Murder rate the highest?
3. What year was the Murder rate the lowest?
4. What year was the Robbery rate the highest?
5. What year was the Robbery rate the lowest?
6. What was the total percentage change in Motor Vehicle Theft between 1998 and 2012?
7. What was [enter your first unique statistic here]?
8. What was [enter your second unique statistic here]?
Q. Quit the program

Enter your selection: 5

The Robbery rate was lowest in 2013

Enter the number of the question you want answered. Enter ‘Q' to quit the program :

1. What were the percentages in population growth for each consecutive year from 1994 - 2013?
2. What year was the Murder rate the highest?
3. What year was the Murder rate the lowest?
4. What year was the Robbery rate the highest?
5. What year was the Robbery rate the lowest?
6. What was the total percentage change in Motor Vehicle Theft between 1998 and 2012?
7. What was [enter your first unique statistic here]?
8. What was [enter your second unique statistic here]?
Q. Quit the program

Enter your selection: Q

Thank you for trying the US Crimes Statistics Program.

Elapsed time in seconds was: 32

Attachment:- Crime1.rar

Reference no: EM131601402

Questions Cloud

Imagine you have been asked to help a novice : Imagine you have been asked to help a novice designer effectively organize his menu content in an application.
Choose and discuss two jobs within law enforcement : Choose two jobs within law enforcement, one that you would like to do, one you would not wish to do.
Explain the rationale for choosing your target market : Explain the rationale for choosing your target market, the rationale for choosing your product and organizational structure you selected to support the launch.
Direct manipulation and virtual environments : Short answer needed (couple sentences per bullet with 1 reference). "Direct Manipulation and Virtual Environments" Please respond to the following:
Design java application that will read file containing data : Design a Java application that will read a file containing data related to the US. Crime statistics from 1994-2013 - What year was the Murder rate the highest
What parts of the film were portrayed realistically : What parts of the film were portrayed realistically. What parts were contrary to what we know about court-related issues
Recent threat or attack on a government agency : Conduct research on a recent threat or attack on a government agency, military organization
Conflicting goals management : Create a Service Operation document that could be used by an organization of your choice.
Explains in-depth the meaning of an idea or thought : Detail is the word of the week. Detail explains in-depth the meaning of an idea or thought. It can be an example or step by step explanation of a process.

Reviews

Write a Review

JAVA Programming Questions & Answers

  Java classes that are implementations of the rectangle class

Write a Java application that enables the user to specify the length, width and location of two instances of a PlaneRectangle and check whether the first lies completely within the second.

  What should a comment at the class level contain

How do you identify a comment so the Javadoc tool will recognize it and what should a comment at the class level contain?

  Write program in java-calculate and display mortgage payment

Write the program in Java (with a graphical user interface) and have it calculate and display the mortgage payment amount from user input of the amount of the mortgage.

  Write a script that inputs several lines of text

Write a script that inputs several lines of text and a search character and uses String method indexOf to determine the number of occurrences of the character in the text.

  Write with basis java structures

Instead of Switch Statement and case studies, which one can I use for line 117 ; Instead of try/catch which code can I use - write with basis java structures

  Wolves and sheep: design a game

This project is designed a game in java. you choose whether you'd like to write a wolf or a sheep agent. Then, you are assigned to either a "sheep" or a "wolf" team.

  Create the html form and call the servlet to print out

1. write a calculator Servlet that adds, subtract, multiples and divides. Create the html form and call the servlet to print out the answer

  Program which defines two unconstrained arrays

The enclosed Java code was suppose to address the following problem, where I require in giving comments/criticism/remarks if possible with respect to the Java coding standards.

  Java program for real estate agent

Write down java program for real estate agent. Program must perform the following tasks: ask users for average house price for the each of past 5 years for single family residence of 1500 square feet.

  Calculate the total value of property for sale

Prompt the user for the name of the input file (listings.txt). Open the listings.txt file and read in property listing information using a buffered FileReader. Calculate the total value of property for sale.

  Implement a parameterized constructor

Implement a parameterized constructor, which will take firstName and lastName of an employee and initialized the respective data members

  Write a tester class snowman in java

Write a tester class Snowman.java?, with a main method that creates different objects of the classes Square and Circle to create a snowman. You can use your creativity to build different parts of the snowman. Print the area and perimeter of each o..

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd