Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
pig-lab
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nguyentd
pig-lab
Commits
bce33e96
Commit
bce33e96
authored
8 years ago
by
nguyentd
Browse files
Options
Downloads
Patches
Plain Diff
Ex2: OSN
parent
4769991f
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
sample-solutions/OSN/tw-count.pig
+5
-5
5 additions, 5 deletions
sample-solutions/OSN/tw-count.pig
sample-solutions/OSN/tw-count.pig~
+4
-4
4 additions, 4 deletions
sample-solutions/OSN/tw-count.pig~
with
9 additions
and
9 deletions
sample-solutions/OSN/tw-count.pig
+
5
−
5
View file @
bce33e96
dataset = LOAD '/sample-input/OSN/tw.txt' AS (id: long, fr: long);
dataset = LOAD '
.
/sample-input/OSN/tw.txt' AS (id: long, fr: long);
-- TODO: check if user IDs are valid (e.g. not null) and clean the dataset
good_data = FILTER dataset BY id is not null and fr is not null;
...
...
@@ -17,7 +17,7 @@
-- find the outliers
outliers = FILTER friends BY followers<2 ;
STORE friends INTO './
local
-output/OSN/twc/';
STORE followings INTO './
local
-output/OSN/following/';
STORE outliers INTO './
local
-output/OSN/outliers/';
STORE friends INTO './
local
-output/OSN/twc/';
STORE friends INTO './
sample
-output/OSN/twc/';
STORE followings INTO './
sample
-output/OSN/following/';
STORE outliers INTO './
sample
-output/OSN/outliers/';
STORE friends INTO './
sample
-output/OSN/twc/';
This diff is collapsed.
Click to expand it.
sample-solutions/OSN/tw-count.pig~
+
4
−
4
View file @
bce33e96
...
...
@@ -17,7 +17,7 @@
-- find the outliers
outliers = FILTER friends BY followers<2 ;
STORE friends INTO './
local
-output/OSN/twc/';
STORE followings INTO './
local
-output/OSN/following/';
STORE outliers INTO './
local
-output/OSN/outliers/';
STORE friends INTO './
local
-output/OSN/twc/';
STORE friends INTO './
sample
-output/OSN/twc/';
STORE followings INTO './
sample
-output/OSN/following/';
STORE outliers INTO './
sample
-output/OSN/outliers/';
STORE friends INTO './
sample
-output/OSN/twc/';
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment