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
""" | |
linecodes.py | |
Credit: StackOverflow via Bas Swinckels | |
URL: https://stackoverflow.com/a/20037521/845744 | |
""" | |
import matplotlib.pyplot as plt | |
import numpy as np | |
def my_lines(ax, pos, *args, **kwargs): | |
if ax == 'x': |
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
m = [[1,2,3],[4,5,6],[7,8,9]] | |
m_t = list(map(list,zip(*m))) | |
# m_t is now -> [[1,4,7], [2,5,8], [3,6,9]] |
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
# aeris_response.py | |
# response_dict is the dictionary returned from a requests.Response.json() method | |
# call. | |
# | |
# Details regarding the response fields can be found at: | |
# https://www.aerisweather.com/support/docs/api/reference/endpoints/observations/#response | |
response_dict = { | |
"success": True, | |
"error": None, |
OlderNewer