-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathmap_me.py
26 lines (20 loc) · 837 Bytes
/
map_me.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
"""
Creates a png format map of an existing polygon data set
"""
import argparse
from isotiles.visual import Visual
parser = argparse.ArgumentParser()
def do_map(the_shape, the_size, the_weight):
"""
"""
v_mod = Visual(shape=the_shape, radial=the_size, weight=the_weight)
v_mod.map_data()
PARSER = argparse.ArgumentParser(
prog='map_me',
description='Creates a png format map of an existing polygon data set')
PARSER.add_argument('-rl', '--radial', default=57, help="radial length in km")
PARSER.add_argument('-wt', '--weight', default='place',
help="polygon intersection weight variable (place or area)")
PARSER.add_argument('-sh', '--shape', default='hex', help="shape (hex or box)")
ARGS = PARSER.parse_args()
do_map(ARGS.shape, ARGS.radial, ARGS.weight)