Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

i want to solve this question with groupbykey or mapReduce in scala spark-shell Second Question [4 Marks]: Assume that you have the following dataset: {45,3,4,44,39,11,7,8,13,21,20,

i want to solve this question with groupbykey or mapReduce in scala spark-shell

image text in transcribed

Second Question [4 Marks]: Assume that you have the following dataset: {45,3,4,44,39,11,7,8,13,21,20, 44,44,12,27,27,29,18,19,19,1,1,31,31,32,1,22,33,31,37,50,41,42}. Notice that the the lowest value in this dataset is 1 and the largest value is 50 . Assume that you want you to find the average and the count of the values in ranges of 10 s where the ranges are . Write a spark job to solve this problem, then trigger the execution by .collect(Q action and print the returned array. (Hint: refer to example 3, lab 6)

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

Database Design And SQL For DB2

Authors: James Cooper

1st Edition

1583473572, 978-1583473573

More Books

Students also viewed these Databases questions