hw6 - CPS216 Data-Intensive Computing Systems - Fall 2011...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CPS216 Data-Intensive Computing Systems - Fall 2011 Assignment 6 (Written) Total points = 100. Due date: Monday, Oct. 24, 2011 (5.00 PM). Submission: In class, or email solutions in pdf or plain text to the TA. You can also drop oF the solutions at the TA’s o±ce. Do not forget to indicate your name on your submission. State all assumptions. ²or questions where descriptive solutions are required, you will be graded both on the correctness and clarity of your reasoning. Question 1 Points 20 This question is based on the following Pig Latin query: clicks = LOAD ‘clicks’ AS (userid, pageid, linkid, viewedat); byuser = GROUP clicks BY userid; result = FOREACH byuser { fltrd = FILTER clicks BY viewedat IS NOT NULL; uniqPages = DISTINCT fltrd.pageid; uniqLinks = DISTINCT fltrd.linkid; GENERATE group, COUNT(uniqPages), COUNT(uniqLinks); }; (I) Draw a valid logical plan, physical plan, and MapReduce plan for this query. (II) Give a valid set of example bags for each of the variables in this Pig Latin query. Note that the variables in this Pig Latin query are: clicks, byuser, ³trd, uniqPages, uniqLinks, and result. See ²igure 4 in the “Pig Latin: A Not-So-²oreign Language for Data Processing” paper on how to present your answer. (III) Is it correct to move the ²ILTER statement to before the GROUP statement? That is, will the following Pig Latin query produce the same ´nal result as the above query: clicks = LOAD ‘clicks’ AS (userid, pageid, linkid, viewedat); fltrd = FILTER clicks BY viewedat IS NOT NULL;
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This document was uploaded on 01/17/2012.

Page1 / 3

hw6 - CPS216 Data-Intensive Computing Systems - Fall 2011...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online