File tree Expand file tree Collapse file tree 2 files changed +28
-20
lines changed Expand file tree Collapse file tree 2 files changed +28
-20
lines changed Original file line number Diff line number Diff line change 1
- mkdir data
1
+ #! /usr/bin/env bash
2
+
3
+ if [ ! -d data ]; then
4
+ mkdir data
5
+ fi
2
6
cd data
3
- curl https://dl.dropbox.com/sh/jjeubxlxuqkzkeq/5W6zkUZXww/million.txt? dl=1 > million.txt
4
- curl https://dl.dropbox.com/s/yuxlaj8okcjta9t/exp.txt? dl=1 > exp.txt
5
- curl https://dl.dropbox.com/s/cbf5skx34grlwy6/lower48.txt? dl=1 > lower48.txt
6
- curl https://dl.dropbox.com/s/gsu2y9vqnx5ps5i/texas.txt? dl=1 > texas.txt
7
- curl https://dl.dropbox.com/s/4zws1nbamorcy9z/x_test.txt? dl=1 > x_test.txt
8
- curl https://dl.dropbox.com/s/mlt4gfqr6n24kxj/y_test.txt? dl=1 > y_test.txt
9
7
8
+ curl -L ' https://dl.dropbox.com/sh/jjeubxlxuqkzkeq/5W6zkUZXww/million.txt?dl=1' > million.txt
9
+ curl -L ' https://dl.dropbox.com/s/yuxlaj8okcjta9t/exp.txt?dl=1' > exp.txt
10
+ curl -L ' https://dl.dropbox.com/s/cbf5skx34grlwy6/lower48.txt?dl=1' > lower48.txt
11
+ curl -L ' https://dl.dropbox.com/s/gsu2y9vqnx5ps5i/texas.txt?dl=1' > texas.txt
12
+ curl -L ' https://dl.dropbox.com/s/4zws1nbamorcy9z/x_test.txt?dl=1' > x_test.txt
13
+ curl -L ' https://dl.dropbox.com/s/mlt4gfqr6n24kxj/y_test.txt?dl=1' > y_test.txt
Original file line number Diff line number Diff line change 1
- echo plotting coordinates
1
+ #! /usr/bin/env bash
2
2
3
+ if [ ! -d data ]; then
4
+ echo ' downloading data'
5
+ ./downloaddata.sh
6
+ fi
7
+
8
+ echo ' plotting coordinates'
3
9
scatter --file ./data/texas.txt
4
10
5
- echo with x and y coords
11
+ echo ' with x and y coords'
6
12
scatter -x ./data/x_test.txt -y ./data/y_test.txt
7
13
8
- echo plotting a histogram
14
+ echo ' plotting a histogram'
9
15
hist --file ./data/exp.txt
10
16
11
- echo with colors
17
+ echo ' with colors'
12
18
hist --file ./data/exp.txt --colour blue
13
19
14
- echo changing the shape of the point
20
+ echo ' changing the shape of the point'
15
21
hist --file ./data/exp.txt --pch .
16
22
17
- echo using stdin
18
- curl https://dl.dropbox.com/u/49171662/example.txt | hist
19
-
20
- echo getting data from a webpage
21
- curl http://www.baseball-reference.com/ \
22
- | grep -o -E " [$]([0-9]+)" | grep -o -E " [0-9]+" \
23
- | hist -b 20 -t " Baseball Payrolls" --height 20 --pch " *"
24
-
23
+ # echo 'using stdin'
24
+ # curl -sL https://dl.dropbox.com/u/49171662/example.txt | hist
25
25
26
+ # echo 'getting data from a webpage'
27
+ # curl -s 'http://www.baseball-reference.com' |
28
+ # grep -o -E '[$][0-9]+' | grep -o -E '[0-9]+' |
29
+ # hist -b 20 -t 'Baseball Payrolls' --height 20 --pch '*'
You can’t perform that action at this time.
0 commit comments