test_prophet.py 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691
  1. # Copyright (c) 2017-present, Facebook, Inc.
  2. # All rights reserved.
  3. #
  4. # This source code is licensed under the BSD-style license found in the
  5. # LICENSE file in the root directory of this source tree. An additional grant
  6. # of patent rights can be found in the PATENTS file in the same directory.
  7. from __future__ import absolute_import
  8. from __future__ import division
  9. from __future__ import print_function
  10. from __future__ import unicode_literals
  11. try:
  12. from StringIO import StringIO
  13. except ImportError:
  14. from io import StringIO
  15. import numpy as np
  16. import pandas as pd
  17. # fb-block 1 start
  18. from unittest import TestCase
  19. from fbprophet import Prophet
  20. # fb-block 1 end
  21. # fb-block 2
  22. class TestProphet(TestCase):
  23. def test_load_models(self):
  24. forecaster = Prophet()
  25. forecaster.get_linear_model()
  26. forecaster.get_logistic_model()
  27. def test_fit_predict(self):
  28. N = DATA.shape[0]
  29. train = DATA.head(N // 2)
  30. future = DATA.tail(N // 2)
  31. forecaster = Prophet()
  32. forecaster.fit(train)
  33. forecaster.predict(future)
  34. def test_fit_predict_no_seasons(self):
  35. N = DATA.shape[0]
  36. train = DATA.head(N // 2)
  37. future = DATA.tail(N // 2)
  38. forecaster = Prophet(weekly_seasonality=False, yearly_seasonality=False)
  39. forecaster.fit(train)
  40. forecaster.predict(future)
  41. def test_fit_predict_no_changepoints(self):
  42. N = DATA.shape[0]
  43. train = DATA.head(N // 2)
  44. future = DATA.tail(N // 2)
  45. forecaster = Prophet(n_changepoints=0)
  46. forecaster.fit(train)
  47. forecaster.predict(future)
  48. def test_setup_dataframe(self):
  49. m = Prophet()
  50. N = DATA.shape[0]
  51. history = DATA.head(N // 2).copy()
  52. history = m.setup_dataframe(history, initialize_scales=True)
  53. self.assertTrue('t' in history)
  54. self.assertEqual(history['t'].min(), 0.0)
  55. self.assertEqual(history['t'].max(), 1.0)
  56. self.assertTrue('y_scaled' in history)
  57. self.assertEqual(history['y_scaled'].max(), 1.0)
  58. def test_get_changepoints(self):
  59. m = Prophet()
  60. N = DATA.shape[0]
  61. history = DATA.head(N // 2).copy()
  62. history = m.setup_dataframe(history, initialize_scales=True)
  63. m.history = history
  64. m.set_changepoints()
  65. cp = m.get_changepoint_indexes()
  66. self.assertEqual(cp.shape[0], m.n_changepoints)
  67. self.assertEqual(len(cp.shape), 1)
  68. self.assertTrue(cp.min() > 0)
  69. self.assertTrue(cp.max() < N)
  70. mat = m.get_changepoint_matrix()
  71. self.assertEqual(mat.shape[0], N // 2)
  72. self.assertEqual(mat.shape[1], m.n_changepoints)
  73. def test_get_zero_changepoints(self):
  74. m = Prophet(n_changepoints=0)
  75. N = DATA.shape[0]
  76. history = DATA.head(N // 2).copy()
  77. history = m.setup_dataframe(history, initialize_scales=True)
  78. m.history = history
  79. m.set_changepoints()
  80. cp = m.get_changepoint_indexes()
  81. self.assertEqual(cp.shape[0], 1)
  82. self.assertEqual(cp[0], 0)
  83. mat = m.get_changepoint_matrix()
  84. self.assertEqual(mat.shape[0], N // 2)
  85. self.assertEqual(mat.shape[1], 1)
  86. def test_fourier_series_weekly(self):
  87. mat = Prophet.fourier_series(DATA['ds'], 7, 3)
  88. # These are from the R forecast package directly.
  89. true_values = np.array([
  90. 0.7818315, 0.6234898, 0.9749279, -0.2225209, 0.4338837, -0.9009689,
  91. ])
  92. self.assertAlmostEqual(np.sum((mat[0] - true_values)**2), 0.0)
  93. def test_fourier_series_yearly(self):
  94. mat = Prophet.fourier_series(DATA['ds'], 365.25, 3)
  95. # These are from the R forecast package directly.
  96. true_values = np.array([
  97. 0.7006152, -0.7135393, -0.9998330, 0.01827656, 0.7262249, 0.6874572,
  98. ])
  99. self.assertAlmostEqual(np.sum((mat[0] - true_values)**2), 0.0)
  100. def test_growth_init(self):
  101. model = Prophet(growth='logistic')
  102. history = DATA.copy()
  103. history['cap'] = history['y'].max()
  104. history = model.setup_dataframe(history, initialize_scales=True)
  105. k, m = model.linear_growth_init(history)
  106. self.assertAlmostEqual(k, 0.3055671)
  107. self.assertAlmostEqual(m, 0.5307511)
  108. k, m = model.logistic_growth_init(history)
  109. self.assertAlmostEqual(k, 1.507925, places=4)
  110. self.assertAlmostEqual(m, -0.08167497, places=4)
  111. def test_piecewise_linear(self):
  112. model = Prophet()
  113. t = np.arange(11.)
  114. m = 0
  115. k = 1.0
  116. deltas = np.array([0.5])
  117. changepoint_ts = np.array([5])
  118. y = model.piecewise_linear(t, deltas, k, m, changepoint_ts)
  119. y_true = np.array([0.0, 1.0, 2.0, 3.0, 4.0, 5.0,
  120. 6.5, 8.0, 9.5, 11.0, 12.5])
  121. self.assertEqual((y - y_true).sum(), 0.0)
  122. t = t[8:]
  123. y_true = y_true[8:]
  124. y = model.piecewise_linear(t, deltas, k, m, changepoint_ts)
  125. self.assertEqual((y - y_true).sum(), 0.0)
  126. def test_piecewise_logistic(self):
  127. model = Prophet()
  128. t = np.arange(11.)
  129. cap = np.ones(11) * 10
  130. m = 0
  131. k = 1.0
  132. deltas = np.array([0.5])
  133. changepoint_ts = np.array([5])
  134. y = model.piecewise_logistic(t, cap, deltas, k, m, changepoint_ts)
  135. y_true = np.array([5.000000, 7.310586, 8.807971, 9.525741, 9.820138,
  136. 9.933071, 9.984988, 9.996646, 9.999252, 9.999833,
  137. 9.999963])
  138. self.assertAlmostEqual((y - y_true).sum(), 0.0, places=5)
  139. t = t[8:]
  140. y_true = y_true[8:]
  141. cap = cap[8:]
  142. y = model.piecewise_logistic(t, cap, deltas, k, m, changepoint_ts)
  143. self.assertAlmostEqual((y - y_true).sum(), 0.0, places=5)
  144. def test_holidays(self):
  145. holidays = pd.DataFrame({
  146. 'ds': pd.to_datetime(['2016-12-25']),
  147. 'holiday': ['xmas'],
  148. 'lower_window': [-1],
  149. 'upper_window': [0],
  150. })
  151. model = Prophet(holidays=holidays)
  152. df = pd.DataFrame({
  153. 'ds': pd.date_range('2016-12-20', '2016-12-31')
  154. })
  155. feats = model.make_holiday_features(df['ds'])
  156. # 11 columns generated even though only 8 overlap
  157. self.assertEqual(feats.shape, (df.shape[0], 2))
  158. self.assertEqual((feats.sum(0) - np.array([1.0, 1.0])).sum(), 0)
  159. holidays = pd.DataFrame({
  160. 'ds': pd.to_datetime(['2016-12-25']),
  161. 'holiday': ['xmas'],
  162. 'lower_window': [-1],
  163. 'upper_window': [10],
  164. })
  165. feats = Prophet(holidays=holidays).make_holiday_features(df['ds'])
  166. # 12 columns generated even though only 8 overlap
  167. self.assertEqual(feats.shape, (df.shape[0], 12))
  168. def test_fit_with_holidays(self):
  169. holidays = pd.DataFrame({
  170. 'ds': pd.to_datetime(['2012-06-06', '2013-06-06']),
  171. 'holiday': ['seans-bday'] * 2,
  172. 'lower_window': [0] * 2,
  173. 'upper_window': [1] * 2,
  174. })
  175. model = Prophet(holidays=holidays, uncertainty_samples=0)
  176. model.fit(DATA).predict()
  177. DATA = pd.read_csv(StringIO("""
  178. ds,y
  179. 2012-05-18,38.23
  180. 2012-05-21,34.03
  181. 2012-05-22,31.0
  182. 2012-05-23,32.0
  183. 2012-05-24,33.03
  184. 2012-05-25,31.91
  185. 2012-05-29,28.84
  186. 2012-05-30,28.19
  187. 2012-05-31,29.6
  188. 2012-06-01,27.72
  189. 2012-06-04,26.9
  190. 2012-06-05,25.87
  191. 2012-06-06,26.81
  192. 2012-06-07,26.31
  193. 2012-06-08,27.1
  194. 2012-06-11,27.01
  195. 2012-06-12,27.4
  196. 2012-06-13,27.27
  197. 2012-06-14,28.29
  198. 2012-06-15,30.01
  199. 2012-06-18,31.41
  200. 2012-06-19,31.91
  201. 2012-06-20,31.6
  202. 2012-06-21,31.84
  203. 2012-06-22,33.05
  204. 2012-06-25,32.06
  205. 2012-06-26,33.1
  206. 2012-06-27,32.23
  207. 2012-06-28,31.36
  208. 2012-06-29,31.1
  209. 2012-07-02,30.77
  210. 2012-07-03,31.2
  211. 2012-07-05,31.47
  212. 2012-07-06,31.73
  213. 2012-07-09,32.17
  214. 2012-07-10,31.47
  215. 2012-07-11,30.97
  216. 2012-07-12,30.81
  217. 2012-07-13,30.72
  218. 2012-07-16,28.25
  219. 2012-07-17,28.09
  220. 2012-07-18,29.11
  221. 2012-07-19,29.0
  222. 2012-07-20,28.76
  223. 2012-07-23,28.75
  224. 2012-07-24,28.45
  225. 2012-07-25,29.34
  226. 2012-07-26,26.85
  227. 2012-07-27,23.71
  228. 2012-07-30,23.15
  229. 2012-07-31,21.71
  230. 2012-08-01,20.88
  231. 2012-08-02,20.04
  232. 2012-08-03,21.09
  233. 2012-08-06,21.92
  234. 2012-08-07,20.72
  235. 2012-08-08,20.72
  236. 2012-08-09,21.01
  237. 2012-08-10,21.81
  238. 2012-08-13,21.6
  239. 2012-08-14,20.38
  240. 2012-08-15,21.2
  241. 2012-08-16,19.87
  242. 2012-08-17,19.05
  243. 2012-08-20,20.01
  244. 2012-08-21,19.16
  245. 2012-08-22,19.44
  246. 2012-08-23,19.44
  247. 2012-08-24,19.41
  248. 2012-08-27,19.15
  249. 2012-08-28,19.34
  250. 2012-08-29,19.1
  251. 2012-08-30,19.09
  252. 2012-08-31,18.06
  253. 2012-09-04,17.73
  254. 2012-09-05,18.58
  255. 2012-09-06,18.96
  256. 2012-09-07,18.98
  257. 2012-09-10,18.81
  258. 2012-09-11,19.43
  259. 2012-09-12,20.93
  260. 2012-09-13,20.71
  261. 2012-09-14,22.0
  262. 2012-09-17,21.52
  263. 2012-09-18,21.87
  264. 2012-09-19,23.29
  265. 2012-09-20,22.59
  266. 2012-09-21,22.86
  267. 2012-09-24,20.79
  268. 2012-09-25,20.28
  269. 2012-09-26,20.62
  270. 2012-09-27,20.32
  271. 2012-09-28,21.66
  272. 2012-10-01,21.99
  273. 2012-10-02,22.27
  274. 2012-10-03,21.83
  275. 2012-10-04,21.95
  276. 2012-10-05,20.91
  277. 2012-10-08,20.4
  278. 2012-10-09,20.23
  279. 2012-10-10,19.64
  280. 2012-10-11,19.75
  281. 2012-10-12,19.52
  282. 2012-10-15,19.52
  283. 2012-10-16,19.48
  284. 2012-10-17,19.88
  285. 2012-10-18,18.98
  286. 2012-10-19,19.0
  287. 2012-10-22,19.32
  288. 2012-10-23,19.5
  289. 2012-10-24,23.23
  290. 2012-10-25,22.56
  291. 2012-10-26,21.94
  292. 2012-10-31,21.11
  293. 2012-11-01,21.21
  294. 2012-11-02,21.18
  295. 2012-11-05,21.25
  296. 2012-11-06,21.17
  297. 2012-11-07,20.47
  298. 2012-11-08,19.99
  299. 2012-11-09,19.21
  300. 2012-11-12,20.07
  301. 2012-11-13,19.86
  302. 2012-11-14,22.36
  303. 2012-11-15,22.17
  304. 2012-11-16,23.56
  305. 2012-11-19,22.92
  306. 2012-11-20,23.1
  307. 2012-11-21,24.32
  308. 2012-11-23,24.0
  309. 2012-11-26,25.94
  310. 2012-11-27,26.15
  311. 2012-11-28,26.36
  312. 2012-11-29,27.32
  313. 2012-11-30,28.0
  314. 2012-12-03,27.04
  315. 2012-12-04,27.46
  316. 2012-12-05,27.71
  317. 2012-12-06,26.97
  318. 2012-12-07,27.49
  319. 2012-12-10,27.84
  320. 2012-12-11,27.98
  321. 2012-12-12,27.58
  322. 2012-12-13,28.24
  323. 2012-12-14,26.81
  324. 2012-12-17,26.75
  325. 2012-12-18,27.71
  326. 2012-12-19,27.41
  327. 2012-12-20,27.36
  328. 2012-12-21,26.26
  329. 2012-12-24,26.93
  330. 2012-12-26,26.51
  331. 2012-12-27,26.05
  332. 2012-12-28,25.91
  333. 2012-12-31,26.62
  334. 2013-01-02,28.0
  335. 2013-01-03,27.77
  336. 2013-01-04,28.76
  337. 2013-01-07,29.42
  338. 2013-01-08,29.06
  339. 2013-01-09,30.59
  340. 2013-01-10,31.3
  341. 2013-01-11,31.72
  342. 2013-01-14,30.95
  343. 2013-01-15,30.1
  344. 2013-01-16,29.85
  345. 2013-01-17,30.14
  346. 2013-01-18,29.66
  347. 2013-01-22,30.73
  348. 2013-01-23,30.82
  349. 2013-01-24,31.08
  350. 2013-01-25,31.54
  351. 2013-01-28,32.47
  352. 2013-01-29,30.79
  353. 2013-01-30,31.24
  354. 2013-01-31,30.98
  355. 2013-02-01,29.73
  356. 2013-02-04,28.11
  357. 2013-02-05,28.64
  358. 2013-02-06,29.05
  359. 2013-02-07,28.65
  360. 2013-02-08,28.55
  361. 2013-02-11,28.26
  362. 2013-02-12,27.37
  363. 2013-02-13,27.91
  364. 2013-02-14,28.5
  365. 2013-02-15,28.32
  366. 2013-02-19,28.93
  367. 2013-02-20,28.46
  368. 2013-02-21,27.28
  369. 2013-02-22,27.13
  370. 2013-02-25,27.27
  371. 2013-02-26,27.39
  372. 2013-02-27,26.87
  373. 2013-02-28,27.25
  374. 2013-03-01,27.78
  375. 2013-03-04,27.72
  376. 2013-03-05,27.52
  377. 2013-03-06,27.45
  378. 2013-03-07,28.58
  379. 2013-03-08,27.96
  380. 2013-03-11,28.14
  381. 2013-03-12,27.83
  382. 2013-03-13,27.08
  383. 2013-03-14,27.04
  384. 2013-03-15,26.65
  385. 2013-03-18,26.49
  386. 2013-03-19,26.55
  387. 2013-03-20,25.86
  388. 2013-03-21,25.74
  389. 2013-03-22,25.73
  390. 2013-03-25,25.13
  391. 2013-03-26,25.21
  392. 2013-03-27,26.09
  393. 2013-03-28,25.58
  394. 2013-04-01,25.53
  395. 2013-04-02,25.42
  396. 2013-04-03,26.25
  397. 2013-04-04,27.07
  398. 2013-04-05,27.39
  399. 2013-04-08,26.85
  400. 2013-04-09,26.59
  401. 2013-04-10,27.57
  402. 2013-04-11,28.02
  403. 2013-04-12,27.4
  404. 2013-04-15,26.52
  405. 2013-04-16,26.92
  406. 2013-04-17,26.63
  407. 2013-04-18,25.69
  408. 2013-04-19,25.73
  409. 2013-04-22,25.97
  410. 2013-04-23,25.98
  411. 2013-04-24,26.11
  412. 2013-04-25,26.14
  413. 2013-04-26,26.85
  414. 2013-04-29,26.98
  415. 2013-04-30,27.77
  416. 2013-05-01,27.43
  417. 2013-05-02,28.97
  418. 2013-05-03,28.31
  419. 2013-05-06,27.57
  420. 2013-05-07,26.89
  421. 2013-05-08,27.12
  422. 2013-05-09,27.04
  423. 2013-05-10,26.68
  424. 2013-05-13,26.82
  425. 2013-05-14,27.07
  426. 2013-05-15,26.6
  427. 2013-05-16,26.13
  428. 2013-05-17,26.25
  429. 2013-05-20,25.76
  430. 2013-05-21,25.66
  431. 2013-05-22,25.16
  432. 2013-05-23,25.06
  433. 2013-05-24,24.31
  434. 2013-05-28,24.1
  435. 2013-05-29,23.32
  436. 2013-05-30,24.55
  437. 2013-05-31,24.35
  438. 2013-06-03,23.85
  439. 2013-06-04,23.52
  440. 2013-06-05,22.9
  441. 2013-06-06,22.97
  442. 2013-06-07,23.29
  443. 2013-06-10,24.33
  444. 2013-06-11,24.03
  445. 2013-06-12,23.77
  446. 2013-06-13,23.73
  447. 2013-06-14,23.63
  448. 2013-06-17,24.02
  449. 2013-06-18,24.21
  450. 2013-06-19,24.31
  451. 2013-06-20,23.9
  452. 2013-06-21,24.53
  453. 2013-06-24,23.94
  454. 2013-06-25,24.25
  455. 2013-06-26,24.16
  456. 2013-06-27,24.66
  457. 2013-06-28,24.88
  458. 2013-07-01,24.81
  459. 2013-07-02,24.41
  460. 2013-07-03,24.52
  461. 2013-07-05,24.37
  462. 2013-07-08,24.71
  463. 2013-07-09,25.48
  464. 2013-07-10,25.8
  465. 2013-07-11,25.81
  466. 2013-07-12,25.91
  467. 2013-07-15,26.28
  468. 2013-07-16,26.32
  469. 2013-07-17,26.65
  470. 2013-07-18,26.18
  471. 2013-07-19,25.88
  472. 2013-07-22,26.05
  473. 2013-07-23,26.13
  474. 2013-07-24,26.51
  475. 2013-07-25,34.36
  476. 2013-07-26,34.01
  477. 2013-07-29,35.43
  478. 2013-07-30,37.63
  479. 2013-07-31,36.8
  480. 2013-08-01,37.49
  481. 2013-08-02,38.05
  482. 2013-08-05,39.19
  483. 2013-08-06,38.55
  484. 2013-08-07,38.87
  485. 2013-08-08,38.54
  486. 2013-08-09,38.5
  487. 2013-08-12,38.22
  488. 2013-08-13,37.02
  489. 2013-08-14,36.65
  490. 2013-08-15,36.56
  491. 2013-08-16,37.08
  492. 2013-08-19,37.81
  493. 2013-08-20,38.41
  494. 2013-08-21,38.32
  495. 2013-08-22,38.55
  496. 2013-08-23,40.55
  497. 2013-08-26,41.34
  498. 2013-08-27,39.64
  499. 2013-08-28,40.55
  500. 2013-08-29,41.28
  501. 2013-08-30,41.29
  502. 2013-09-03,41.87
  503. 2013-09-04,41.78
  504. 2013-09-05,42.66
  505. 2013-09-06,43.95
  506. 2013-09-09,44.04
  507. 2013-09-10,43.6
  508. 2013-09-11,45.04
  509. 2013-09-12,44.75
  510. 2013-09-13,44.31
  511. 2013-09-16,42.51
  512. 2013-09-17,45.07
  513. 2013-09-18,45.23
  514. 2013-09-19,45.98
  515. 2013-09-20,47.49
  516. 2013-09-23,47.19
  517. 2013-09-24,48.45
  518. 2013-09-25,49.46
  519. 2013-09-26,50.39
  520. 2013-09-27,51.24
  521. 2013-09-30,50.23
  522. 2013-10-01,50.42
  523. 2013-10-02,50.28
  524. 2013-10-03,49.18
  525. 2013-10-04,51.04
  526. 2013-10-07,50.52
  527. 2013-10-08,47.14
  528. 2013-10-09,46.77
  529. 2013-10-10,49.05
  530. 2013-10-11,49.11
  531. 2013-10-14,49.51
  532. 2013-10-15,49.5
  533. 2013-10-16,51.14
  534. 2013-10-17,52.21
  535. 2013-10-18,54.22
  536. 2013-10-21,53.85
  537. 2013-10-22,52.68
  538. 2013-10-23,51.9
  539. 2013-10-24,52.45
  540. 2013-10-25,51.95
  541. 2013-10-28,50.23
  542. 2013-10-29,49.4
  543. 2013-10-30,49.01
  544. 2013-10-31,50.21
  545. 2013-11-01,49.75
  546. 2013-11-04,48.22
  547. 2013-11-05,50.11
  548. 2013-11-06,49.12
  549. 2013-11-07,47.56
  550. 2013-11-08,47.53
  551. 2013-11-11,46.2
  552. 2013-11-12,46.61
  553. 2013-11-13,48.71
  554. 2013-11-14,48.99
  555. 2013-11-15,49.01
  556. 2013-11-18,45.83
  557. 2013-11-19,46.36
  558. 2013-11-20,46.43
  559. 2013-11-21,46.7
  560. 2013-11-22,46.23
  561. 2013-11-25,44.82
  562. 2013-11-26,45.89
  563. 2013-11-27,46.49
  564. 2013-11-29,47.01
  565. 2013-12-02,47.06
  566. 2013-12-03,46.73
  567. 2013-12-04,48.62
  568. 2013-12-05,48.34
  569. 2013-12-06,47.94
  570. 2013-12-09,48.84
  571. 2013-12-10,50.25
  572. 2013-12-11,49.38
  573. 2013-12-12,51.83
  574. 2013-12-13,53.32
  575. 2013-12-16,53.81
  576. 2013-12-17,54.86
  577. 2013-12-18,55.57
  578. 2013-12-19,55.05
  579. 2013-12-20,55.12
  580. 2013-12-23,57.77
  581. 2013-12-24,57.96
  582. 2013-12-26,57.73
  583. 2013-12-27,55.44
  584. 2013-12-30,53.71
  585. 2013-12-31,54.65
  586. 2014-01-02,54.71
  587. 2014-01-03,54.56
  588. 2014-01-06,57.2
  589. 2014-01-07,57.92
  590. 2014-01-08,58.23
  591. 2014-01-09,57.22
  592. 2014-01-10,57.94
  593. 2014-01-13,55.91
  594. 2014-01-14,57.74
  595. 2014-01-15,57.6
  596. 2014-01-16,57.19
  597. 2014-01-17,56.3
  598. 2014-01-21,58.51
  599. 2014-01-22,57.51
  600. 2014-01-23,56.63
  601. 2014-01-24,54.45
  602. 2014-01-27,53.55
  603. 2014-01-28,55.14
  604. 2014-01-29,53.53
  605. 2014-01-30,61.08
  606. 2014-01-31,62.57
  607. 2014-02-03,61.48
  608. 2014-02-04,62.75
  609. 2014-02-05,62.19
  610. 2014-02-06,62.16
  611. 2014-02-07,64.32
  612. 2014-02-10,63.55
  613. 2014-02-11,64.85
  614. 2014-02-12,64.45
  615. 2014-02-13,67.33
  616. 2014-02-14,67.09
  617. 2014-02-18,67.3
  618. 2014-02-19,68.06
  619. 2014-02-20,69.63
  620. 2014-02-21,68.59
  621. 2014-02-24,70.78
  622. 2014-02-25,69.85
  623. 2014-02-26,69.26
  624. 2014-02-27,68.94
  625. 2014-02-28,68.46
  626. 2014-03-03,67.41
  627. 2014-03-04,68.8
  628. 2014-03-05,71.57
  629. 2014-03-06,70.84
  630. 2014-03-07,69.8
  631. 2014-03-10,72.03
  632. 2014-03-11,70.1
  633. 2014-03-12,70.88
  634. 2014-03-13,68.83
  635. 2014-03-14,67.72
  636. 2014-03-17,68.74
  637. 2014-03-18,69.19
  638. 2014-03-19,68.24
  639. 2014-03-20,66.97
  640. 2014-03-21,67.24
  641. 2014-03-24,64.1
  642. 2014-03-25,64.89
  643. 2014-03-26,60.39
  644. 2014-03-27,60.97
  645. 2014-03-28,60.01
  646. 2014-03-31,60.24
  647. """), parse_dates=['ds'])