Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
%matplotlib inline | |
from matplotlib import pyplot as plt | |
import numpy as np | |
# each point is length, width, type (0, 1) | |
data = [[3, 1.5, 1], | |
[2, 1, 0], | |
[4, 1.5, 1], | |
[3, 1, 0], | |
[3.5, .5, 1], |
This file contains 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
import pandas as pd | |
from pandas_datareader import data as web | |
import matplotlib.pyplot as plt | |
from datetime import datetime | |
start = datetime(2016,1,1) | |
end = datetime(2017,1,1) | |
assets = ['AAPL', 'FB', 'TSLA'] |
This file contains 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
# import python's number crunchers | |
from pandas_datareader import data as web | |
import pandas as pd | |
import numpy as np | |
assets = ['AAPL', 'GM', 'GE', 'FB', 'WMT'] | |
df = pd.DataFrame() | |
for stock in assets: |
This file contains 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
adj_close | |
ticker AAPL MSFT WMT | |
date | |
2015-12-31 101.696810 53.096499 58.379766 | |
2016-01-04 101.783763 52.445713 58.532144 | |
2016-01-05 99.233131 52.684973 59.922592 | |
2016-01-06 97.291172 51.727934 60.522580 | |
2016-01-07 93.185040 49.928701 61.932075 |