Created
August 1, 2016 17:03
-
-
Save boertel/68343a5967052dd7532eeeadf450d48b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
charts = [ | |
{ | |
'key': 'foresults', | |
'title': 'Top Air Origins', | |
}, | |
{ | |
'key': 'horesults', | |
'title': 'Top Hotel Origins', | |
}, | |
{ | |
'key': 'hdresults', | |
'title': 'Top Hotel Destinations', | |
}, | |
{ | |
'key': 'fsresults', | |
'title': 'Alternate Searched Air Destinations', | |
}, | |
{ | |
'key': 'fbresults', | |
'title': 'Alternate Booked Air Destinations', | |
}, | |
{ | |
'key': 'hsresults', | |
'title': 'Alternate Searched Hotel Destinations', | |
}, | |
{ | |
'key': 'hbresults', | |
'title': 'Alternate Booked Hotel Destinations', | |
}, | |
] | |
start = 53 | |
for definition in charts: | |
chart = create_chart(results.get(definition['key']), start, definition['title']) | |
worksheet.insert_chart('D%s' % start, chart) | |
columns = 'A%(row)s:B%(row)s' % {'row': (start - 2)} | |
worksheet.merge_range(columns, definition['title'], merge_format) | |
start += 27 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment