Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please read the question carefully and also include (//) comments in your code, Thank you. Objective To build a complete working Java program that applies

Please read the question carefully and also include (//) comments in your code, Thank you.

Objective

To build a complete working Java program that applies arrays and list processing.

Overview & Instruction

Write a menu-driven to analyze data from customer ratings of products your company sells. Your program should begin by reading in a file of raw review data (filename reviews.txt). This file is guaranteed as a precondition to be no greater than 1000 lines of data. Some sample data are below describing what is on each line of the file:

123 20170113 4

456 20161226 3

The format for each line is: {productNumber} {purchaseDate} {rating}

The product numbers will match exclusively with the list found in the file (products.txt). Avoid hard-coding test data, but instead pull from the provided file. Here is a sample:

123 Widget

243 Frumkin

The dates included are integers but in a strict format: yyyymmdd. The ratings will exclusively range from 1...5. The years will exclusive range from 2012 through this year.

Be sure to read all of the raw data into either parallel arrays or consider alternately an array of Reviewobjects. The product number/name data should also be stored using arrays.

Your program should be menu-driven to allow a user to analyze data from the review data set. The menu can be driven simply using dialog boxes but should allow the user to see data and then return to a "home" menu in case they want to retrieve information from a different query. Include the following data summaries for the user:

Individual product review as a histogram. Use percentages. Each asterisk would indicate 10%.

Product 123 - Widget

5 *****

4 ***

3 **

2

1

Overall lifetime product review averages (sorted high-to-low)

Product Ave

xxx x.x

xxx x.x xxx x.x

xxx x.x

Average monthly product reviews by month

Month: 04/2017 Product 234 - Frumkin

Ave: x.x

Perform error-checking to insure that:

Any month and/or year are valid (month 1..12 and year is 2012 through this year)

Any part number entered matches one in the list

Be sure to consider modularity in this program whether using a procedural approach or an object oriented approach.

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

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions

Question

Do you currently have a team agreement?

Answered: 1 week ago

Question

How will the members be held accountable?

Answered: 1 week ago