ntroduction: This assignment is to provide practice in using the Java I/O techniques discussed in the Module 10 video lectures and readings. Although the main focus of this assignment is Java I/O techniques, Java design and implementation techniques discussed in earlier modules should be incorporated in to this assignment. Problem: Supplied is a data file from the US Census which contains data from US school districts and reports statistics related to child poverty (http://www.census.gov/did/www/saipe/data/highlights/2013.html). It is desired to have a summary report which calculate basic statistics at the state level. Desired Implementation: Java 8 implementation to read the supplied text data and produce a report similar to the below:     There should be two separate “programs” (two separate .java files each with a main method), one to read the text data file and write a reformatted file to be read by the second program which will create the report to standard out. Note before the report is displayed, a single line with “File: “ then the path of the input file for the report is displayed. The first program is to create a data file (not the report) which provides a pre-processed view of the data supplied to it either by striping off the unneeded fields or by stripping off the unneeded fields and summing the data by state code. The numbers should not be formatted and no additional records should be produced. The second program should read the file produced by the first program and produce the report in the format shown in the above image. This program should format the numbers and produce the file path information and column headings. The first program will have 3 run-time parameters, the data source file path, the destination file path, and the number of records in the data file (13486) . If the program does not use the last run-time parameter, it should still accept it. The second program will have 2 run-time parameters, the input file path and the number of records. If the program does not use the last run-time parameter, it should still accept it. Features and Restrictions: This assignment is an individual effort. Collaboration with other students on design approaches, implementation techniques, etc. as well as using the course's Discussion Board and other course resources are encouraged but the design, implementation, and submitted files must be your own creation. A good reference for the Java 8 API is at: http://docs.oracle.com/javase/8/docs/api/ The programs should use standard (SE) Java 8 code and compile without errors or warnings. It should also run without errors or warnings when given valid input. The programs should provide reasonable parameter validation (correct number of parameters, reasonable values, etc.). The programs should not use any Java collections (ArrayList, Map, Vector, etc.) except standard Java arrays. Collections are introduced in a later module. The file produced by the first program should not be deleted after running the report program. The program's code should be reasonable formatted and commented as demonstrated so far in the course. Resources: File: SmallAreaIncomePovertyEstData.txt – contains the small area poverty data. It is a standard 8-bit readable text file. File: SmallAreaIncomePoverty

Np Ms Office 365/Excel 2016 I Ntermed
1st Edition
ISBN:9781337508841
Author:Carey
Publisher:Carey
Chapter8: Working With Advanced Functions
Section8.3: Conditional Formatting And Functions
Problem 5QC
icon
Related questions
Question

Program in JAVA and please show output and comment the program

Introduction:

This assignment is to provide practice in using the Java I/O techniques discussed in the Module 10 video lectures and readings. Although the main focus of this assignment is Java I/O techniques, Java design and implementation techniques discussed in earlier modules should be incorporated in to this assignment.

Problem:

Supplied is a data file from the US Census which contains data from US school districts and reports statistics related to child poverty (http://www.census.gov/did/www/saipe/data/highlights/2013.html). It is desired to have a summary report which calculate basic statistics at the state level.

Desired Implementation:
Java 8 implementation to read the supplied text data and produce a report similar to the below:

 

 

There should be two separate “programs” (two separate .java files each with a main method), one to read the text data file and write a reformatted file to be read by the second program which will create the report to standard out. Note before the report is displayed, a single line with “File: “ then the path of the input file for the report is displayed.

The first program is to create a data file (not the report) which provides a pre-processed view of the data supplied to it either by striping off the unneeded fields or by stripping off the unneeded fields and summing the data by state code. The numbers should not be formatted and no additional records should be produced.

The second program should read the file produced by the first program and produce the report in the format shown in the above image. This program should format the numbers and produce the file path information and column headings.

The first program will have 3 run-time parameters, the data source file path, the destination file path, and the number of records in the data file (13486) . If the program does not use the last run-time parameter, it should still accept it.

The second program will have 2 run-time parameters, the input file path and the number of records. If the program does not use the last run-time parameter, it should still accept it.

Features and Restrictions: This assignment is an individual effort. Collaboration with other students on design approaches, implementation techniques, etc. as well as using the course's Discussion Board and other course resources are encouraged but the design, implementation, and submitted files must be your own creation. A good reference for the Java 8 API is at: http://docs.oracle.com/javase/8/docs/api/ The programs should use standard (SE) Java 8 code and compile without errors or warnings. It should also run without errors or warnings when given valid input. The programs should provide reasonable parameter validation (correct number of parameters, reasonable values, etc.). The programs should not use any Java collections (ArrayList, Map, Vector, etc.) except standard Java arrays. Collections are introduced in a later module. The file produced by the first program should not be deleted after running the report program. The program's code should be reasonable formatted and commented as demonstrated so far in the course.

Resources:

File: SmallAreaIncomePovertyEstData.txt – contains the small area poverty data. It is a standard 8-bit readable text file.

File: SmallAreaIncomePovertyEstLayout.txt – contains information about the field layout of the SmallAreaIncomePovertyEstData.txt file.

32
2,790,136
483,411
99,599
20.60
33
1,472,055
205,461
19,714
9.60
34
10,552,547
1,488,882
222,992
14.98
103,790
666,553
35
2,085,287
368,816
28.14
19,901,043
9,848,060
21.74
23.09
36
3,066,336
1,673,310
37
386,419
12,685
398,688
144 ,867
38
723,393
113,921
11.13
11,570,743
3,851,487
3,931,430
12,773,801
1,065,907
39
1,958,998
20.35
682,548
627,584
1,999,741
159,355
787,482
148,002
40
21.22
118,023
342,181
31,368
194,639
41
18.81
42
17.11
44
19.68
45
4,790,785
24.72
46
844,877
24,675
16.67
1,091,900
5,101,161
23.82
23.49
47
6,778,703
260,103
48
26,452,422
1,198,322
49
2,900,872
642,722
85,745
13.34
50
940,840
92,223
11,990
13.00
51
14.10
17.12
8,260,405
1,352,420
190,734
53
6,971,406
1,151,175
197,126
1,854,304
23.09
16.33
11.78
54
279,484
64,539
55
5,956,920
963,445
157,356
56
582,360
99,290
11,701
bins
Transcribed Image Text:32 2,790,136 483,411 99,599 20.60 33 1,472,055 205,461 19,714 9.60 34 10,552,547 1,488,882 222,992 14.98 103,790 666,553 35 2,085,287 368,816 28.14 19,901,043 9,848,060 21.74 23.09 36 3,066,336 1,673,310 37 386,419 12,685 398,688 144 ,867 38 723,393 113,921 11.13 11,570,743 3,851,487 3,931,430 12,773,801 1,065,907 39 1,958,998 20.35 682,548 627,584 1,999,741 159,355 787,482 148,002 40 21.22 118,023 342,181 31,368 194,639 41 18.81 42 17.11 44 19.68 45 4,790,785 24.72 46 844,877 24,675 16.67 1,091,900 5,101,161 23.82 23.49 47 6,778,703 260,103 48 26,452,422 1,198,322 49 2,900,872 642,722 85,745 13.34 50 940,840 92,223 11,990 13.00 51 14.10 17.12 8,260,405 1,352,420 190,734 53 6,971,406 1,151,175 197,126 1,854,304 23.09 16.33 11.78 54 279,484 64,539 55 5,956,920 963,445 157,356 56 582,360 99,290 11,701 bins
Population Child Population Child Poverity Population % Child Poverty
State
25.18
4,833,722
735,132
8,688,149
2,959,373
48,909,205
5,268,367
3,747,676
01
814,377
205,023
16,118
02
132,740
12.14
24.41
25.71
22.03
15.44
13.12
17.09
29.14
23.00
24.47
04
1,182,931
516,950
6,667,268
902,796
593,629
288,777
132,920
05
06
1,468,715
08
139,381
09
77,895
10
925,749
147,239
25,169
11
646,449
70,507
20,544
12
19,552,860
2,948,361
678,022
13
10,010,465
1,821,201
445 ,608
1,404,054
1,612,136
15
216,496
29,375
13.57
16
314,294
56,633
18.02
17
17,704,060
2,224,288
427,235
19.21
19.45
14.67
16.10
18
6,570,099
1,165,146
226,599
19
3,090,416
529,306
77,634
20
2,893,957
523,686
84,325
Transcribed Image Text:Population Child Population Child Poverity Population % Child Poverty State 25.18 4,833,722 735,132 8,688,149 2,959,373 48,909,205 5,268,367 3,747,676 01 814,377 205,023 16,118 02 132,740 12.14 24.41 25.71 22.03 15.44 13.12 17.09 29.14 23.00 24.47 04 1,182,931 516,950 6,667,268 902,796 593,629 288,777 132,920 05 06 1,468,715 08 139,381 09 77,895 10 925,749 147,239 25,169 11 646,449 70,507 20,544 12 19,552,860 2,948,361 678,022 13 10,010,465 1,821,201 445 ,608 1,404,054 1,612,136 15 216,496 29,375 13.57 16 314,294 56,633 18.02 17 17,704,060 2,224,288 427,235 19.21 19.45 14.67 16.10 18 6,570,099 1,165,146 226,599 19 3,090,416 529,306 77,634 20 2,893,957 523,686 84,325
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Follow-up Questions
Read through expert solutions to related follow-up questions below.
Follow-up Question

how did you run the file ?

Solution
Bartleby Expert
SEE SOLUTION
Knowledge Booster
Hiring Problem
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Np Ms Office 365/Excel 2016 I Ntermed
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage
Principles of Information Systems (MindTap Course…
Principles of Information Systems (MindTap Course…
Computer Science
ISBN:
9781285867168
Author:
Ralph Stair, George Reynolds
Publisher:
Cengage Learning
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781305627482
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning