cloud Posted October 19, 2022 Report Posted October 19, 2022 Evarkanna pig scripting vacha . E roju assignment dead line undi and forgot about it . It is a simple query kani naku asalu idea ledu . Evarkanna vaste please ping me Quote
kasi Posted October 19, 2022 Report Posted October 19, 2022 42 minutes ago, cloud said: Evarkanna pig scripting vacha . E roju assignment dead line undi and forgot about it . It is a simple query kani naku asalu idea ledu . Evarkanna vaste please ping me hadoop lo pig aa? Quote
kasi Posted October 19, 2022 Report Posted October 19, 2022 43 minutes ago, cloud said: Evarkanna pig scripting vacha . E roju assignment dead line undi and forgot about it . It is a simple query kani naku asalu idea ledu . Evarkanna vaste please ping me question ikada vey Quote
cloud Posted October 19, 2022 Author Report Posted October 19, 2022 Use the ml-100k dataset, and Pig Latin in HDP: find the least rated one star movie (rating < 2.0). Most rated means, number of users rated that movie is the lowest and that movie is one star (rating <2.0). Quote
cloud Posted October 19, 2022 Author Report Posted October 19, 2022 Just now, cloud said: Use the ml-100k dataset, and Pig Latin in HDP: find the least rated one star movie (rating < 2.0). Most rated means, number of users rated that movie is the lowest and that movie is one star (rating <2.0). https://grouplens.org/datasets/movielens/100k/ ml 100k data set dentlo undi Sample code : ratings = LOAD '/user/raj_ops/ml-100k/u.data' AS (userID:int, movieID:int, rating:int, ratingTime:int); moviesdata = LOAD '/user/raj_ops/ml-100k/u.item' USING PigStorage('|') AS (movieID:int, movieTitle:chararray, releaseDate:chararray); nameLookup = FOREACH moviesdata GENERATE movieID, movieTitle, ToUnixTime(ToDate(releaseDate, 'dd-MMM-yyyy')) AS releaseTime; ratingsByMovie = GROUP ratings BY movieID; avgRatings = FOREACH ratingsByMovie GENERATE group as movieID, AVG(ratings.rating) as avgRating; fiveStarMovies = FILTER avgRatings BY avgRating > 4.0; fiveStarsWithName = JOIN fiveStarMovies BY movieID, nameLookup BY movieID; fiveStarMovies = ORDER fiveStarsWithName BY nameLookup::releaseTime; DUMP fiveStarMovies; Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.