├── .gitignore ├── README.md ├── crypto_trader.ipynb ├── debug.ipynb ├── model ├── bitcoin.model.h5 ├── ethereum.model.h5 ├── numeraire.model.h5 ├── qtum.model.h5 └── ripple.model.h5 ├── v1 ├── .DS_Store ├── .idea │ ├── environment.iml │ ├── misc.xml │ ├── modules.xml │ └── workspace.xml ├── __init__.py ├── crypto_trader.ipynb ├── crypto_trader_v2.ipynb ├── cryptocurrencypricehistory │ ├── bitcoin_cash_price.csv │ ├── bitcoin_dataset.csv │ ├── bitcoin_price.csv │ ├── bitconnect_price.csv │ ├── dash_price.csv │ ├── ethereum_classic_price.csv │ ├── ethereum_dataset.csv │ ├── ethereum_price.csv │ ├── iota_price.csv │ ├── jason_always_buy_price.csv │ ├── jason_buy_sell_hold_price.csv │ ├── jason_never_buy_price.csv │ ├── litecoin_price.csv │ ├── monero_price.csv │ ├── nem_price.csv │ ├── neo_price.csv │ ├── numeraire_price.csv │ ├── omisego_price.csv │ ├── qtum_price.csv │ ├── ripple_price.csv │ ├── stratis_price.csv │ └── waves_price.csv ├── dummy_benchmarks.ipynb ├── env.py ├── portfolio.py ├── simulator.py └── trader.py └── v2 ├── __init__.py ├── cryptocurrencypricehistory ├── bitcoin_cash_price.csv ├── bitcoin_dataset.csv ├── bitcoin_price.csv ├── bitconnect_price.csv ├── dash_price.csv ├── debug_always_buy_price.csv ├── debug_buy_sell_hold_price.csv ├── debug_never_buy_price.csv ├── ethereum_classic_price.csv ├── ethereum_dataset.csv ├── ethereum_price.csv ├── iota_price.csv ├── litecoin_price.csv ├── monero_price.csv ├── nem_price.csv ├── neo_price.csv ├── numeraire_price.csv ├── omisego_price.csv ├── qtum_price.csv ├── ripple_price.csv ├── stratis_price.csv └── waves_price.csv ├── ddqn_agent.ipynb ├── ddqn_agent.py ├── env.ipynb ├── env.py ├── portfolio.py ├── run_benchmarks.py ├── simple_agents.py └── utils.py /.gitignore: -------------------------------------------------------------------------------- 1 | *.pyc 2 | /.ipynb_checkpoints 3 | .DS_Store 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # GT-Research -------------------------------------------------------------------------------- /model/bitcoin.model.h5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/model/bitcoin.model.h5 -------------------------------------------------------------------------------- /model/ethereum.model.h5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/model/ethereum.model.h5 -------------------------------------------------------------------------------- /model/numeraire.model.h5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/model/numeraire.model.h5 -------------------------------------------------------------------------------- /model/qtum.model.h5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/model/qtum.model.h5 -------------------------------------------------------------------------------- /model/ripple.model.h5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/model/ripple.model.h5 -------------------------------------------------------------------------------- /v1/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/v1/.DS_Store -------------------------------------------------------------------------------- /v1/.idea/environment.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 11 | -------------------------------------------------------------------------------- /v1/.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /v1/.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /v1/.idea/workspace.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 12 | 13 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 70 | 71 | 72 | 79 | 80 | 81 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 109 | 110 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 141 | 142 | 153 | 154 | 172 | 173 | 191 | 192 | 212 | 213 | 234 | 235 | 258 | 259 | 260 | 262 | 263 | 264 | 265 | 1509221855273 266 | 270 | 271 | 272 | 273 | 274 | 275 | 276 | 277 | 278 | 279 | 280 | 281 | 282 | 283 | 284 | 285 | 286 | 287 | 288 | 289 | 290 | 291 | 292 | 293 | 294 | 295 | 296 | 298 | 299 | 300 | 301 | 302 | 303 | 304 | 305 | 306 | 307 | 308 | 309 | 310 | 311 | 312 | 313 | 314 | 315 | 316 | 317 | 318 | 319 | 320 | 321 | 322 | 323 | 324 | 325 | 326 | 327 | 328 | 329 | 330 | 331 | 332 | 333 | 334 | 335 | 336 | 337 | 338 | 339 | 340 | -------------------------------------------------------------------------------- /v1/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/v1/__init__.py -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/bitcoin_cash_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",602.68,626.21,602.45,616.30,"375,367,000","10,105,200,000" 3 | "Nov 06, 2017",630.31,657.34,602.65,602.65,"794,105,000","10,566,600,000" 4 | "Nov 05, 2017",619.91,635.72,579.13,630.70,"816,028,000","10,390,900,000" 5 | "Nov 04, 2017",635.35,642.05,571.12,620.45,"1,161,370,000","10,647,200,000" 6 | "Nov 03, 2017",587.32,684.53,577.86,625.32,"1,682,210,000","9,839,760,000" 7 | "Nov 02, 2017",527.68,610.39,514.52,587.22,"1,632,060,000","8,840,010,000" 8 | "Nov 01, 2017",438.30,538.26,437.91,531.83,"1,152,230,000","7,342,250,000" 9 | "Oct 31, 2017",449.37,454.07,431.76,439.05,"343,799,000","7,527,260,000" 10 | "Oct 30, 2017",458.45,478.42,417.62,448.23,"796,409,000","7,679,000,000" 11 | "Oct 29, 2017",420.47,526.12,408.40,451.92,"2,002,440,000","7,042,260,000" 12 | "Oct 28, 2017",369.54,425.44,369.06,423.35,"781,037,000","6,183,520,000" 13 | "Oct 27, 2017",338.30,372.81,338.24,367.57,"501,989,000","5,655,870,000" 14 | "Oct 26, 2017",332.11,350.94,331.21,338.20,"234,967,000","5,550,700,000" 15 | "Oct 25, 2017",326.59,334.38,320.38,332.13,"151,935,000","5,457,720,000" 16 | "Oct 24, 2017",315.90,340.45,311.48,326.89,"267,442,000","5,278,410,000" 17 | "Oct 23, 2017",330.67,332.28,309.87,315.60,"191,558,000","5,524,790,000" 18 | "Oct 22, 2017",323.50,355.52,323.50,331.66,"355,546,000","5,405,020,000" 19 | "Oct 21, 2017",326.75,328.45,317.46,323.36,"129,938,000","5,458,980,000" 20 | "Oct 20, 2017",330.90,332.98,323.08,327.44,"160,204,000","5,527,860,000" 21 | "Oct 19, 2017",339.27,339.27,326.27,330.81,"195,578,000","5,667,070,000" 22 | "Oct 18, 2017",373.65,376.18,313.77,339.17,"477,184,000","6,240,990,000" 23 | "Oct 17, 2017",313.70,394.96,309.64,371.73,"1,008,160,000","5,239,520,000" 24 | "Oct 16, 2017",315.26,318.02,310.52,313.64,"117,797,000","5,265,400,000" 25 | "Oct 15, 2017",322.42,323.59,307.68,314.95,"133,385,000","5,384,760,000" 26 | "Oct 14, 2017",321.54,327.42,317.35,321.96,"164,137,000","5,369,720,000" 27 | "Oct 13, 2017",314.15,323.08,304.38,321.46,"288,210,000","5,242,630,000" 28 | "Oct 12, 2017",315.47,330.13,310.71,313.21,"262,066,000","5,262,390,000" 29 | "Oct 11, 2017",320.20,321.26,312.13,314.90,"131,577,000","5,341,000,000" 30 | "Oct 10, 2017",313.22,352.02,311.70,321.59,"367,809,000","5,224,170,000" 31 | "Oct 09, 2017",342.76,342.76,289.04,314.16,"288,075,000","5,716,320,000" 32 | "Oct 08, 2017",360.09,362.46,337.00,342.21,"203,754,000","6,004,940,000" 33 | "Oct 07, 2017",363.60,364.88,356.06,360.78,"91,004,000","6,062,860,000" 34 | "Oct 06, 2017",355.44,371.28,354.96,363.01,"182,031,000","5,926,540,000" 35 | "Oct 05, 2017",358.42,371.19,348.45,355.75,"268,341,000","5,971,260,000" 36 | "Oct 04, 2017",404.20,404.45,354.55,358.45,"251,584,000","6,729,640,000" 37 | "Oct 03, 2017",421.79,421.79,395.74,404.18,"130,247,000","7,022,370,000" 38 | "Oct 02, 2017",415.87,430.86,411.84,421.19,"219,590,000","6,921,580,000" 39 | "Oct 01, 2017",433.38,436.94,415.15,415.15,"164,290,000","7,207,770,000" 40 | "Sep 30, 2017",436.64,445.62,432.53,432.63,"150,565,000","7,258,880,000" 41 | "Sep 29, 2017",447.66,447.92,426.99,436.77,"148,725,000","7,441,960,000" 42 | "Sep 28, 2017",456.71,465.20,433.50,447.81,"300,421,000","7,592,000,000" 43 | "Sep 27, 2017",441.86,460.00,439.41,457.31,"197,885,000","7,343,490,000" 44 | "Sep 26, 2017",445.36,458.25,441.83,441.83,"165,303,000","7,400,020,000" 45 | "Sep 25, 2017",419.65,450.13,419.65,445.80,"302,272,000","6,971,280,000" 46 | "Sep 24, 2017",428.80,433.04,419.25,421.03,"114,527,000","7,121,950,000" 47 | "Sep 23, 2017",415.31,432.96,407.45,428.50,"189,127,000","6,895,970,000" 48 | "Sep 22, 2017",417.92,435.44,402.77,415.09,"241,905,000","6,937,170,000" 49 | "Sep 21, 2017",475.83,480.00,413.75,416.26,"316,731,000","7,898,300,000" 50 | "Sep 20, 2017",526.74,527.72,471.09,476.05,"669,264,000","8,741,670,000" 51 | "Sep 19, 2017",480.64,550.41,450.05,527.88,"802,321,000","7,975,010,000" 52 | "Sep 18, 2017",422.09,479.69,422.09,479.32,"458,550,000","7,001,640,000" 53 | "Sep 17, 2017",438.90,438.90,384.06,419.86,"221,828,000","7,279,520,000" 54 | "Sep 16, 2017",424.49,450.98,388.20,440.22,"313,583,000","7,039,590,000" 55 | "Sep 15, 2017",369.49,448.39,301.69,424.02,"707,231,000","6,126,800,000" 56 | "Sep 14, 2017",504.22,510.47,367.04,367.04,"257,431,000","8,359,650,000" 57 | "Sep 13, 2017",509.47,519.20,471.22,503.61,"340,344,000","8,445,540,000" 58 | "Sep 12, 2017",539.03,559.22,505.01,510.41,"273,825,000","8,934,220,000" 59 | "Sep 11, 2017",537.19,556.25,515.67,537.81,"274,712,000","8,902,570,000" 60 | "Sep 10, 2017",546.48,546.75,484.09,537.07,"289,508,000","9,055,430,000" 61 | "Sep 09, 2017",584.73,586.18,539.15,547.47,"234,578,000","9,688,150,000" 62 | "Sep 08, 2017",654.37,687.30,557.50,583.10,"809,763,000","10,840,500,000" 63 | "Sep 07, 2017",636.85,707.98,603.50,652.86,"1,082,380,000","10,548,500,000" 64 | "Sep 06, 2017",541.28,642.69,539.96,638.18,"693,240,000","8,964,700,000" 65 | "Sep 05, 2017",514.90,550.95,458.78,541.71,"338,978,000","8,527,100,000" 66 | "Sep 04, 2017",608.26,608.26,500.75,517.24,"328,957,000","10,072,200,000" 67 | "Sep 03, 2017",578.27,617.41,563.59,607.43,"344,862,000","9,574,520,000" 68 | "Sep 02, 2017",621.96,642.05,560.58,575.90,"350,478,000","10,297,000,000" 69 | "Sep 01, 2017",588.40,645.52,586.73,622.17,"393,839,000","9,740,460,000" 70 | "Aug 31, 2017",576.25,603.69,572.14,588.17,"298,144,000","9,538,750,000" 71 | "Aug 30, 2017",549.32,604.69,535.92,575.21,"443,856,000","9,092,300,000" 72 | "Aug 29, 2017",596.13,599.30,528.32,552.93,"370,017,000","9,866,110,000" 73 | "Aug 28, 2017",619.70,626.88,595.52,596.18,"216,273,000","10,254,800,000" 74 | "Aug 27, 2017",625.89,654.87,589.63,620.90,"402,718,000","10,357,000,000" 75 | "Aug 26, 2017",641.88,646.93,622.36,625.32,"193,414,000","10,616,100,000" 76 | "Aug 25, 2017",627.06,665.41,624.30,641.05,"348,632,000","10,365,600,000" 77 | "Aug 24, 2017",670.03,697.32,617.31,628.11,"407,177,000","11,071,100,000" 78 | "Aug 23, 2017",690.96,715.67,651.32,669.40,"501,983,000","11,416,800,000" 79 | "Aug 22, 2017",596.19,734.88,570.27,690.88,"1,393,260,000","9,844,620,000" 80 | "Aug 21, 2017",723.70,756.59,573.47,599.63,"1,123,400,000","11,943,100,000" 81 | "Aug 20, 2017",772.42,858.96,683.94,712.87,"1,494,020,000","12,742,600,000" 82 | "Aug 19, 2017",697.04,1091.97,625.16,754.56,"3,196,230,000","11,498,100,000" 83 | "Aug 18, 2017",458.67,764.07,458.67,690.24,"3,087,490,000","7,565,590,000" 84 | "Aug 17, 2017",301.02,460.53,293.10,460.53,"744,605,000","4,964,980,000" 85 | "Aug 16, 2017",297.97,307.62,290.21,300.21,"106,436,000","4,914,350,000" 86 | "Aug 15, 2017",298.19,306.52,292.88,297.86,"133,924,000","4,917,480,000" 87 | "Aug 14, 2017",296.10,327.39,293.50,297.68,"174,968,000","4,882,720,000" 88 | "Aug 13, 2017",316.29,317.47,298.05,298.05,"120,722,000","5,215,330,000" 89 | "Aug 12, 2017",327.82,341.85,313.70,317.09,"126,007,000","5,405,200,000" 90 | "Aug 11, 2017",275.88,351.16,275.02,328.24,"233,971,000","4,548,600,000" 91 | "Aug 10, 2017",305.21,311.68,274.68,275.95,"136,637,000","5,031,790,000" 92 | "Aug 09, 2017",345.28,349.32,298.61,303.89,"165,032,000","5,691,960,000" 93 | "Aug 08, 2017",321.35,386.29,309.61,345.49,"274,880,000","5,297,390,000" 94 | "Aug 07, 2017",223.76,373.87,223.76,319.69,"346,546,000","3,688,360,000" 95 | "Aug 06, 2017",212.18,223.70,203.44,220.66,"107,606,000","3,497,290,000" 96 | "Aug 05, 2017",231.11,273.04,200.98,213.15,"144,043,000","3,809,330,000" 97 | "Aug 04, 2017",362.18,386.93,233.05,233.05,"185,038,000","5,969,720,000" 98 | "Aug 03, 2017",448.49,519.28,364.05,364.05,"161,518,000","7,392,030,000" 99 | "Aug 02, 2017",382.38,756.93,309.33,452.66,"416,207,000","6,302,360,000" 100 | "Aug 01, 2017",294.60,426.11,210.38,380.01,"65,988,800",- 101 | "Jul 31, 2017",346.36,347.82,266.19,294.46,"1,075,960",- 102 | "Jul 30, 2017",385.14,385.14,316.25,345.66,"606,695",- 103 | "Jul 29, 2017",410.56,423.73,323.73,384.77,"737,815",- 104 | "Jul 28, 2017",386.65,465.18,217.06,406.05,"1,230,160",- 105 | "Jul 27, 2017",417.10,460.97,367.78,385.48,"533,207",- 106 | "Jul 26, 2017",407.08,486.16,321.79,365.82,"1,784,640",- 107 | "Jul 25, 2017",441.35,541.66,338.09,406.90,"524,908",- 108 | "Jul 24, 2017",412.58,578.89,409.21,440.70,"190,952",- 109 | "Jul 23, 2017",555.89,578.97,411.78,413.06,"85,013",- 110 | -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/bitconnect_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",260.04,273.18,260.04,271.27,"22,712,300","555,997,000" 3 | "Nov 06, 2017",276.58,279.72,259.64,259.85,"19,432,300","591,355,000" 4 | "Nov 05, 2017",278.10,285.64,273.37,276.28,"14,591,800","594,608,000" 5 | "Nov 04, 2017",270.45,284.62,259.07,278.66,"66,891,000","578,248,000" 6 | "Nov 03, 2017",262.93,284.64,260.10,271.12,"25,755,600","1,934,570,000" 7 | "Nov 02, 2017",251.29,273.73,251.29,263.27,"23,900,000","1,846,340,000" 8 | "Nov 01, 2017",239.45,251.29,234.88,250.93,"24,030,900","1,757,760,000" 9 | "Oct 31, 2017",227.38,239.52,226.79,239.52,"18,364,400","1,667,460,000" 10 | "Oct 30, 2017",225.77,230.18,223.09,228.12,"22,568,300","1,653,970,000" 11 | "Oct 29, 2017",211.72,233.22,211.18,227.10,"11,138,200","1,549,720,000" 12 | "Oct 28, 2017",213.13,217.36,209.66,211.84,"10,550,800","1,558,580,000" 13 | "Oct 27, 2017",216.65,220.70,210.38,212.55,"14,048,500","1,582,930,000" 14 | "Oct 26, 2017",206.38,220.18,205.15,216.59,"15,882,500","1,506,580,000" 15 | "Oct 25, 2017",193.74,206.68,188.80,206.32,"17,013,600","1,405,090,000" 16 | "Oct 24, 2017",196.65,201.47,186.31,193.70,"12,298,000","1,424,770,000" 17 | "Oct 23, 2017",204.72,208.28,193.84,198.57,"13,730,900","1,481,770,000" 18 | "Oct 22, 2017",208.50,210.75,198.85,205.04,"9,944,220","1,507,780,000" 19 | "Oct 21, 2017",213.01,218.42,204.56,210.40,"10,211,700","1,538,750,000" 20 | "Oct 20, 2017",199.81,216.68,198.23,213.46,"15,662,400","1,442,010,000" 21 | "Oct 19, 2017",195.58,202.03,194.07,199.79,"14,086,400","1,410,190,000" 22 | "Oct 18, 2017",193.93,196.44,178.70,195.38,"13,234,800","1,395,380,000" 23 | "Oct 17, 2017",199.63,200.25,191.38,193.95,"14,142,600","1,434,990,000" 24 | "Oct 16, 2017",193.05,200.68,190.66,199.63,"14,092,700","1,385,880,000" 25 | "Oct 15, 2017",200.83,201.44,186.43,193.03,"9,190,960","1,440,370,000" 26 | "Oct 14, 2017",196.68,201.51,193.34,199.74,"12,375,600","1,409,300,000" 27 | "Oct 13, 2017",188.67,204.19,187.51,196.72,"18,181,900","1,350,390,000" 28 | "Oct 12, 2017",166.71,188.09,166.23,188.09,"15,616,200","1,182,750,000" 29 | "Oct 11, 2017",161.34,168.28,158.95,166.59,"13,011,800","1,143,640,000" 30 | "Oct 10, 2017",158.71,166.74,158.71,161.25,"13,035,600","1,116,440,000" 31 | "Oct 09, 2017",148.29,161.37,146.63,158.66,"12,646,700","1,034,940,000" 32 | "Oct 08, 2017",142.71,148.93,142.33,148.31,"6,956,630","995,090,000" 33 | "Oct 07, 2017",141.85,144.33,139.16,144.15,"6,342,670","984,296,000" 34 | "Oct 06, 2017",138.96,143.83,138.68,141.86,"10,787,200","958,272,000" 35 | "Oct 05, 2017",135.21,140.32,132.93,138.96,"8,245,120","931,554,000" 36 | "Oct 04, 2017",136.92,138.58,134.12,135.09,"7,468,280","941,932,000" 37 | "Oct 03, 2017",139.07,139.75,134.20,136.58,"8,298,420","955,766,000" 38 | "Oct 02, 2017",139.19,140.60,134.72,139.08,"11,113,800","953,552,000" 39 | "Oct 01, 2017",136.23,139.33,134.03,139.33,"5,808,050","932,178,000" 40 | "Sep 30, 2017",130.13,136.54,128.68,136.16,"7,830,160","889,567,000" 41 | "Sep 29, 2017",131.15,132.31,123.58,130.11,"10,871,800","895,647,000" 42 | "Sep 28, 2017",126.30,131.58,125.18,131.26,"12,807,500","861,593,000" 43 | "Sep 27, 2017",117.41,127.13,117.36,126.31,"10,526,200","800,032,000" 44 | "Sep 26, 2017",117.50,120.41,116.41,117.76,"10,629,600","796,741,000" 45 | "Sep 25, 2017",109.68,119.57,109.51,117.50,"10,414,100","742,949,000" 46 | "Sep 24, 2017",113.12,113.27,108.57,110.11,"4,950,760","765,508,000" 47 | "Sep 23, 2017",109.38,113.91,108.24,113.17,"5,640,310","739,413,000" 48 | "Sep 22, 2017",108.61,113.21,107.07,109.69,"6,933,750","733,372,000" 49 | "Sep 21, 2017",116.67,117.45,107.42,108.73,"6,427,510","787,024,000" 50 | "Sep 20, 2017",117.55,121.48,114.45,117.25,"8,498,270","792,175,000" 51 | "Sep 19, 2017",122.20,123.11,114.60,117.67,"9,224,430","822,711,000" 52 | "Sep 18, 2017",106.62,122.23,106.49,122.00,"8,192,160","716,916,000" 53 | "Sep 17, 2017",109.75,110.94,102.81,106.84,"5,350,380","737,226,000" 54 | "Sep 16, 2017",111.11,116.01,105.02,109.85,"5,683,580","744,652,000" 55 | "Sep 15, 2017",97.42,113.75,89.36,111.22,"8,539,660","652,107,000" 56 | "Sep 14, 2017",115.97,117.38,96.71,96.71,"6,367,800","775,543,000" 57 | "Sep 13, 2017",123.14,123.70,112.60,115.97,"6,315,510","822,282,000" 58 | "Sep 12, 2017",125.29,130.91,122.22,123.50,"6,861,080","835,911,000" 59 | "Sep 11, 2017",121.88,128.20,120.76,125.70,"7,083,720","812,292,000" 60 | "Sep 10, 2017",129.70,129.70,118.94,122.92,"4,644,030","863,579,000" 61 | "Sep 09, 2017",128.51,131.51,125.21,130.05,"6,225,680","854,520,000" 62 | "Sep 08, 2017",137.68,139.78,123.23,128.29,"7,051,050","914,556,000" 63 | "Sep 07, 2017",135.88,138.67,132.52,137.61,"7,564,730","901,778,000" 64 | "Sep 06, 2017",130.25,142.16,128.84,136.18,"8,049,390","863,537,000" 65 | "Sep 05, 2017",114.74,131.57,108.93,129.42,"8,537,600","756,793,000" 66 | "Sep 04, 2017",128.26,129.55,110.68,114.13,"30,395,600","845,031,000" 67 | "Sep 03, 2017",131.71,135.06,125.87,130.99,"5,244,490","866,869,000" 68 | "Sep 02, 2017",141.11,142.80,128.00,131.33,"5,056,030","926,918,000" 69 | "Sep 01, 2017",135.66,140.97,133.47,140.97,"7,854,700","890,229,000" 70 | "Aug 31, 2017",135.60,136.88,132.24,135.63,"6,633,480","888,920,000" 71 | "Aug 30, 2017",128.06,137.29,127.68,136.06,"9,923,160","838,560,000" 72 | "Aug 29, 2017",119.01,129.24,114.84,128.24,"9,907,640","778,470,000" 73 | "Aug 28, 2017",114.84,120.45,86.11,118.75,"6,444,290","750,345,000" 74 | "Aug 27, 2017",116.11,129.98,101.65,114.99,"4,895,670","757,691,000" 75 | "Aug 26, 2017",100.14,136.51,93.25,116.13,"995,116","652,789,000" 76 | "Aug 25, 2017",123.40,149.89,38.98,100.87,"3,353,200","803,652,000" 77 | "Aug 24, 2017",128.05,131.49,119.89,127.08,"8,552,010","832,860,000" 78 | "Aug 23, 2017",120.20,130.43,119.72,127.97,"9,692,110","781,010,000" 79 | "Aug 22, 2017",116.16,121.95,106.55,120.44,"6,273,350","754,043,000" 80 | "Aug 21, 2017",116.32,118.05,112.68,115.91,"7,667,050","754,278,000" 81 | "Aug 20, 2017",119.53,119.61,114.63,116.77,"4,730,720","774,327,000" 82 | "Aug 19, 2017",121.01,132.04,111.47,120.04,"6,751,140","783,024,000" 83 | "Aug 18, 2017",117.65,124.19,115.06,121.08,"7,858,910","760,435,000" 84 | "Aug 17, 2017",119.23,122.91,115.32,117.90,"9,416,780","769,810,000" 85 | "Aug 16, 2017",112.38,119.41,107.07,119.36,"8,065,040","724,865,000" 86 | "Aug 15, 2017",113.03,116.79,104.35,112.26,"8,375,150","728,298,000" 87 | "Aug 14, 2017",103.30,112.83,98.87,112.73,"7,806,160","664,460,000" 88 | "Aug 13, 2017",104.71,113.37,100.17,103.23,"5,104,100","672,851,000" 89 | "Aug 12, 2017",98.88,106.88,97.91,104.76,"6,396,390","634,327,000" 90 | "Aug 11, 2017",91.57,100.27,91.22,98.96,"8,535,500","586,851,000" 91 | "Aug 10, 2017",85.94,92.18,85.46,91.54,"8,170,850","550,213,000" 92 | "Aug 09, 2017",86.45,86.89,83.16,85.91,"6,557,630","552,995,000" 93 | "Aug 08, 2017",83.13,87.32,83.03,86.51,"8,050,680","530,677,000" 94 | "Aug 07, 2017",79.20,84.90,78.36,83.05,"4,506,370","505,097,000" 95 | "Aug 06, 2017",79.13,81.21,75.75,79.32,"3,382,890","504,140,000" 96 | "Aug 05, 2017",70.72,80.61,70.72,79.13,"4,215,220","450,089,000" 97 | "Aug 04, 2017",69.41,71.10,67.85,70.90,"4,766,590","441,261,000" 98 | "Aug 03, 2017",65.09,69.85,64.73,69.35,"4,382,480","413,366,000" 99 | "Aug 02, 2017",50.73,70.30,49.78,64.93,"3,277,460","321,857,000" 100 | "Aug 01, 2017",65.98,66.14,41.09,52.44,"261,126","416,441,000" 101 | "Jul 31, 2017",61.29,66.64,57.91,66.14,"1,578,510","386,447,000" 102 | "Jul 30, 2017",65.08,65.16,61.26,61.52,"2,147,470","409,831,000" 103 | "Jul 29, 2017",69.08,69.23,64.04,64.96,"2,912,860","434,587,000" 104 | "Jul 28, 2017",65.28,69.94,64.79,69.28,"4,174,750","410,202,000" 105 | "Jul 27, 2017",63.01,66.09,62.21,65.09,"3,508,340","395,556,000" 106 | "Jul 26, 2017",63.57,64.46,60.63,62.68,"3,436,370","398,636,000" 107 | "Jul 25, 2017",67.01,67.01,60.14,63.65,"3,566,120","413,094,000" 108 | "Jul 24, 2017",61.33,68.22,58.44,67.02,"3,991,940","374,541,000" 109 | "Jul 23, 2017",67.36,67.85,58.75,60.14,"2,132,900","410,971,000" 110 | "Jul 22, 2017",67.23,70.84,65.63,67.31,"3,077,890","409,779,000" 111 | "Jul 21, 2017",70.31,70.55,65.47,67.21,"4,225,470","423,696,000" 112 | "Jul 20, 2017",56.44,72.00,56.44,69.79,"4,378,970","334,334,000" 113 | "Jul 19, 2017",58.38,60.22,55.72,56.61,"3,140,970","345,452,000" 114 | "Jul 18, 2017",55.72,59.98,53.81,58.29,"3,540,910","329,330,000" 115 | "Jul 17, 2017",47.74,55.83,47.74,55.49,"3,778,790","281,529,000" 116 | "Jul 16, 2017",44.22,50.56,29.87,48.05,"2,100,690","260,770,000" 117 | "Jul 15, 2017",55.45,55.55,44.57,44.57,"2,687,210","383,760,000" 118 | "Jul 14, 2017",57.60,58.57,53.94,55.53,"3,445,520","398,102,000" 119 | "Jul 13, 2017",57.99,58.89,57.02,57.64,"3,024,130","400,400,000" 120 | "Jul 12, 2017",54.99,58.86,53.61,58.26,"2,740,060","379,392,000" 121 | "Jul 11, 2017",53.64,56.96,53.28,55.07,"2,767,260","368,502,000" 122 | "Jul 10, 2017",58.67,59.60,53.45,53.97,"2,949,720","402,702,000" 123 | "Jul 09, 2017",60.22,60.45,58.61,58.96,"1,992,460","412,952,000" 124 | "Jul 08, 2017",56.60,60.25,56.60,60.18,"2,447,650","387,783,000" 125 | "Jul 07, 2017",59.13,59.79,56.58,56.58,"4,205,810","404,767,000" 126 | "Jul 06, 2017",57.11,63.80,56.92,59.06,"3,277,810","390,587,000" 127 | "Jul 05, 2017",55.52,57.30,53.62,57.08,"2,954,260","379,307,000" 128 | "Jul 04, 2017",53.24,55.52,53.22,55.48,"2,748,610","363,460,000" 129 | "Jul 03, 2017",51.81,54.06,51.35,53.36,"3,417,230","353,379,000" 130 | "Jul 02, 2017",50.04,52.40,49.62,52.04,"1,326,100","341,010,000" 131 | "Jul 01, 2017",51.37,52.15,49.61,50.04,"2,650,800","349,775,000" 132 | "Jun 30, 2017",51.94,53.10,50.86,51.39,"2,126,610","353,252,000" 133 | "Jun 29, 2017",52.06,52.82,51.04,51.84,"2,865,970","353,750,000" 134 | "Jun 28, 2017",51.31,52.62,49.94,52.11,"2,985,300","348,397,000" 135 | "Jun 27, 2017",49.50,50.77,46.29,50.56,"2,410,340","335,744,000" 136 | "Jun 26, 2017",51.11,52.74,47.31,48.33,"2,220,370","346,232,000" 137 | "Jun 25, 2017",52.76,54.14,50.46,51.16,"2,464,490","357,030,000" 138 | "Jun 24, 2017",55.65,56.40,51.81,52.87,"2,270,790","376,295,000" 139 | "Jun 23, 2017",52.31,56.73,51.25,55.67,"2,353,480","353,360,000" 140 | "Jun 22, 2017",51.25,52.30,50.28,52.30,"2,264,670","345,886,000" 141 | "Jun 21, 2017",52.41,52.67,48.98,51.27,"1,981,900","353,405,000" 142 | "Jun 20, 2017",51.36,52.76,51.08,52.42,"1,991,020","346,100,000" 143 | "Jun 19, 2017",50.96,51.66,50.90,51.38,"1,827,540","343,207,000" 144 | "Jun 18, 2017",51.02,51.62,50.50,50.90,"1,066,710","343,305,000" 145 | "Jun 17, 2017",50.69,51.19,50.27,51.03,"1,436,890","340,842,000" 146 | "Jun 16, 2017",49.16,51.44,46.92,50.94,"1,359,210","330,219,000" 147 | "Jun 15, 2017",48.01,50.28,43.45,49.18,"1,655,390","322,219,000" 148 | "Jun 14, 2017",50.89,53.96,46.35,47.83,"1,804,340","341,224,000" 149 | "Jun 13, 2017",45.91,50.87,45.91,50.87,"1,609,630","307,656,000" 150 | "Jun 12, 2017",53.42,53.42,41.72,45.68,"2,295,830","357,687,000" 151 | "Jun 11, 2017",54.11,57.52,50.63,53.00,"1,762,110","361,918,000" 152 | "Jun 10, 2017",50.04,59.60,42.61,54.04,"3,783,760","326,419,000" 153 | "Jun 09, 2017",41.33,50.40,41.25,49.97,"2,787,430","268,196,000" 154 | "Jun 08, 2017",36.18,41.43,35.42,41.43,"2,176,920","233,903,000" 155 | "Jun 07, 2017",38.00,38.39,35.20,35.93,"3,101,570","245,393,000" 156 | "Jun 06, 2017",32.24,39.78,32.24,37.99,"2,430,580","207,988,000" 157 | "Jun 05, 2017",25.55,32.86,25.55,32.14,"2,170,880","164,708,000" 158 | "Jun 04, 2017",25.53,25.80,24.94,25.55,"1,719,260","164,484,000" 159 | "Jun 03, 2017",24.03,25.66,23.84,25.59,"2,741,120","154,747,000" 160 | "Jun 02, 2017",22.19,24.19,21.99,24.19,"1,512,120","142,856,000" 161 | "Jun 01, 2017",18.93,22.95,18.93,22.18,"2,466,910","121,713,000" 162 | "May 31, 2017",17.00,18.97,17.00,18.90,"1,228,390","109,246,000" 163 | "May 30, 2017",17.22,17.79,16.59,16.92,"801,777","110,582,000" 164 | "May 29, 2017",15.96,17.51,15.54,17.20,"825,630","102,399,000" 165 | "May 28, 2017",14.86,16.68,14.71,15.99,"405,591","95,355,900" 166 | "May 27, 2017",15.31,16.36,13.47,14.63,"551,952","98,179,600" 167 | "May 26, 2017",15.56,17.57,14.07,15.26,"591,390","99,749,800" 168 | "May 25, 2017",13.57,23.37,11.98,15.67,"6,153,930","86,953,600" 169 | "May 24, 2017",13.21,14.35,13.12,13.60,"1,025,590","84,554,600" 170 | "May 23, 2017",12.26,13.34,12.22,13.19,"662,390","78,464,700" 171 | "May 22, 2017",12.60,13.32,11.75,12.28,"834,180","80,620,000" 172 | "May 21, 2017",12.34,12.93,12.20,12.52,"545,026","78,880,200" 173 | "May 20, 2017",11.23,12.38,11.23,12.35,"653,438","71,772,600" 174 | "May 19, 2017",10.73,11.37,10.72,11.22,"670,821","68,513,600" 175 | "May 18, 2017",10.04,10.87,10.02,10.72,"819,691","64,102,400" 176 | "May 17, 2017",9.80,10.35,9.61,10.11,"783,389","62,539,500" 177 | "May 16, 2017",9.20,10.08,8.95,9.81,"765,059","58,670,700" 178 | "May 15, 2017",8.95,9.26,8.51,9.10,"496,905","57,036,400" 179 | "May 14, 2017",8.49,8.88,8.15,8.79,"397,657","54,087,400" 180 | "May 13, 2017",7.39,8.45,7.03,8.45,"480,450","47,075,500" 181 | "May 12, 2017",7.71,8.04,7.29,7.41,"448,407","49,032,700" 182 | "May 11, 2017",7.71,8.03,7.17,7.70,"407,025","49,044,900" 183 | "May 10, 2017",7.93,8.01,7.30,7.69,"499,177","50,406,400" 184 | "May 09, 2017",8.02,8.33,7.61,7.93,"704,454","50,921,800" 185 | "May 08, 2017",7.95,8.30,7.62,8.01,"808,585","50,377,900" 186 | "May 07, 2017",8.22,8.39,7.48,7.95,"266,678","51,681,300" 187 | "May 06, 2017",5.84,8.42,5.65,8.22,"875,112","36,310,900" 188 | "May 05, 2017",6.99,7.27,5.78,5.78,"566,343","43,198,800" 189 | "May 04, 2017",7.55,7.71,6.65,7.00,"556,024","46,609,100" 190 | "May 03, 2017",7.89,8.00,7.58,7.61,"716,542","48,652,600" 191 | "May 02, 2017",7.96,9.00,7.69,7.88,"578,471","49,072,400" 192 | "May 01, 2017",8.89,9.22,8.19,8.19,"483,599","54,709,600" 193 | "Apr 30, 2017",8.95,9.02,8.74,8.88,"391,218","55,090,300" 194 | "Apr 29, 2017",9.15,9.15,8.91,8.97,"557,753","56,271,900" 195 | "Apr 28, 2017",8.45,9.17,8.45,9.14,"433,870","51,889,500" 196 | "Apr 27, 2017",8.01,9.62,6.86,8.45,"715,582","49,191,200" 197 | "Apr 26, 2017",9.25,9.35,7.92,8.01,"862,259","56,757,800" 198 | "Apr 25, 2017",9.77,9.99,9.14,9.25,"615,853","59,895,000" 199 | "Apr 24, 2017",9.77,9.97,9.63,9.78,"581,280","59,861,300" 200 | "Apr 23, 2017",10.07,10.07,9.64,9.74,"294,309","61,638,000" 201 | "Apr 22, 2017",9.87,10.16,9.78,10.07,"442,488","60,365,000" 202 | "Apr 21, 2017",10.06,10.08,9.50,9.87,"474,630","61,440,400" 203 | "Apr 20, 2017",10.19,10.39,9.70,10.05,"388,381","62,223,000" 204 | "Apr 19, 2017",9.89,10.66,9.89,10.18,"495,149","60,314,300" 205 | "Apr 18, 2017",8.74,10.38,8.74,9.74,"1,048,750","53,297,500" 206 | "Apr 17, 2017",9.70,9.78,7.59,8.74,"801,362","59,082,700" 207 | "Apr 16, 2017",10.78,10.84,8.50,9.70,"737,619","65,626,200" 208 | "Apr 15, 2017",9.80,11.45,9.08,10.80,"1,077,470","58,750,800" 209 | "Apr 14, 2017",12.05,12.69,8.27,9.69,"201,720","72,172,000" 210 | "Apr 13, 2017",10.62,17.63,10.62,11.95,"1,951,160","63,522,800" 211 | "Apr 12, 2017",8.39,10.57,8.37,10.55,"902,695","50,133,900" 212 | "Apr 11, 2017",6.13,8.50,6.13,8.41,"771,597","36,618,600" 213 | "Apr 10, 2017",5.91,6.16,5.48,6.12,"595,244","35,273,600" 214 | "Apr 09, 2017",5.73,6.20,5.73,5.92,"470,292","34,156,000" 215 | "Apr 08, 2017",5.43,5.80,5.36,5.73,"458,324","32,329,000" 216 | "Apr 07, 2017",5.17,5.51,5.02,5.45,"614,199","30,770,800" 217 | "Apr 06, 2017",4.80,5.22,4.80,5.20,"499,333","28,510,400" 218 | "Apr 05, 2017",4.77,4.81,4.66,4.79,"355,818","28,317,800" 219 | "Apr 04, 2017",4.49,4.85,4.43,4.76,"398,884","26,668,800" 220 | "Apr 03, 2017",3.91,4.66,3.91,4.42,"414,450","23,190,700" 221 | "Apr 02, 2017",4.02,4.23,3.88,3.91,"149,998","23,780,900" 222 | "Apr 01, 2017",3.53,4.04,3.49,4.01,"432,916","20,858,600" 223 | "Mar 31, 2017",3.35,3.59,3.34,3.49,"277,557","19,395,400" 224 | "Mar 30, 2017",3.41,3.43,3.30,3.35,"313,656","19,700,100" 225 | "Mar 29, 2017",3.34,3.44,3.25,3.40,"250,322","19,176,200" 226 | "Mar 28, 2017",3.25,3.40,3.23,3.34,"340,582","18,635,300" 227 | "Mar 27, 2017",2.99,3.29,2.93,3.25,"303,282","17,109,800" 228 | "Mar 26, 2017",3.05,3.15,2.90,2.97,"165,270","17,464,100" 229 | "Mar 25, 2017",2.70,4.42,2.34,3.04,"377,669","15,418,900" 230 | "Mar 24, 2017",2.02,3.91,2.01,3.32,"347,994","11,530,000" 231 | "Mar 23, 2017",1.83,2.08,1.78,2.02,"244,700","10,431,300" 232 | "Mar 22, 2017",1.89,1.94,1.77,1.83,"162,423","10,741,700" 233 | "Mar 21, 2017",1.79,1.95,1.77,1.89,"248,776","10,195,800" 234 | "Mar 20, 2017",1.74,1.80,1.70,1.79,"261,732","9,891,750" 235 | "Mar 19, 2017",1.61,1.79,1.59,1.74,"200,786","9,129,360" 236 | "Mar 18, 2017",1.73,1.77,1.54,1.60,"233,726","9,815,210" 237 | "Mar 17, 2017",1.83,1.90,1.73,1.73,"239,185","10,355,500" 238 | "Mar 16, 2017",1.89,1.94,1.76,1.84,"231,056","10,683,100" 239 | "Mar 15, 2017",1.89,1.98,1.86,1.89,"296,537","10,676,500" 240 | "Mar 14, 2017",1.86,1.97,1.86,1.89,"197,787","10,499,500" 241 | "Mar 13, 2017",1.74,1.99,1.72,1.86,"207,174","9,805,420" 242 | "Mar 12, 2017",1.88,2.00,1.66,1.73,"209,145","10,574,100" 243 | "Mar 11, 2017",1.65,2.04,1.65,1.88,"329,288","8,976,540" 244 | "Mar 10, 2017",1.57,1.96,1.57,1.65,"231,193","8,538,000" 245 | "Mar 09, 2017",0.910759,6.90,0.904785,1.57,"391,543","4,953,980" 246 | "Mar 08, 2017",0.928324,2.29,0.892919,0.910482,"80,489","5,043,800" 247 | "Mar 07, 2017",0.929928,0.965031,0.902599,0.928556,"112,631","5,046,350" 248 | "Mar 06, 2017",0.877932,0.948389,0.877303,0.929657,"144,511","4,758,800" 249 | "Mar 05, 2017",0.860446,0.890336,0.854322,0.877690,"99,353","4,658,870" 250 | "Mar 04, 2017",0.876560,0.901431,0.848197,0.861036,"118,768","4,741,050" 251 | "Mar 03, 2017",0.849622,0.897957,0.849622,0.874886,"133,898","4,588,430" 252 | "Mar 02, 2017",0.843463,0.867530,0.833101,0.849830,"112,199","4,549,750" 253 | "Mar 01, 2017",0.804026,0.847651,0.803913,0.841962,"94,260","4,332,560" 254 | "Feb 28, 2017",0.805227,0.831538,0.797892,0.803977,"107,824","4,333,750" 255 | "Feb 27, 2017",0.798417,0.819324,0.798143,0.804716,"71,439","4,292,460" 256 | "Feb 26, 2017",0.780171,0.814878,0.769603,0.799392,"75,564","4,190,100" 257 | "Feb 25, 2017",0.798545,0.821233,0.764979,0.779878,"96,943","4,283,810" 258 | "Feb 24, 2017",0.720091,0.833797,0.710127,0.800726,"80,798","3,858,450" 259 | "Feb 23, 2017",0.750903,0.800626,0.697684,0.716413,"104,601","4,018,590" 260 | "Feb 22, 2017",0.765145,0.800321,0.663462,0.751017,"102,991","4,088,710" 261 | "Feb 21, 2017",0.743569,0.788681,0.742046,0.765488,"46,477","3,968,830" 262 | "Feb 20, 2017",0.722645,0.744402,0.718499,0.744051,"79,052","3,845,050" 263 | "Feb 19, 2017",0.723668,0.759755,0.718855,0.722082,"17,807","3,840,990" 264 | "Feb 18, 2017",0.714177,0.770619,0.712649,0.723435,"69,567","3,786,090" 265 | "Feb 17, 2017",0.737502,0.765716,0.711911,0.712135,"73,305","3,905,080" 266 | "Feb 16, 2017",0.726066,0.762640,0.725988,0.738451,"64,234","3,839,920" 267 | "Feb 15, 2017",0.731512,0.748031,0.721461,0.725943,"84,565","3,864,230" 268 | "Feb 14, 2017",0.711982,0.744774,0.665671,0.730306,"84,926","3,756,710" 269 | "Feb 13, 2017",0.696483,0.718306,0.615641,0.711195,"100,391","3,670,810" 270 | "Feb 12, 2017",0.701552,0.724620,0.693313,0.696708,"90,321","3,693,230" 271 | "Feb 11, 2017",0.634346,0.728807,0.621720,0.702202,"73,165","3,335,540" 272 | "Feb 10, 2017",0.567441,0.652978,0.546511,0.634202,"136,220","2,979,990" 273 | "Feb 09, 2017",0.574614,0.635086,0.529744,0.566729,"40,765","3,013,100" 274 | "Feb 08, 2017",0.425789,0.620504,0.425789,0.573734,"97,396","2,230,210" 275 | "Feb 07, 2017",0.447859,0.516073,0.422868,0.425400,"65,544","2,343,170" 276 | "Feb 06, 2017",0.465675,0.531860,0.445042,0.447002,"92,361","2,372,230" 277 | "Feb 05, 2017",0.568783,0.594951,0.465195,0.465195,"22,814","2,893,950" 278 | "Feb 04, 2017",0.513954,0.618865,0.511836,0.568446,"41,471","2,611,770" 279 | "Feb 03, 2017",0.424369,0.616739,0.423258,0.513246,"104,851","2,151,070" 280 | "Feb 02, 2017",0.376986,0.510052,0.374696,0.424510,"49,021","1,908,590" 281 | "Feb 01, 2017",0.234603,0.625286,0.234330,0.380666,"70,857","1,186,290" 282 | "Jan 31, 2017",0.201900,0.248894,0.192904,0.234476,"38,955","1,019,790" 283 | "Jan 30, 2017",0.183540,0.211474,0.183411,0.201773,"25,986","926,047" 284 | "Jan 29, 2017",0.185211,0.191636,0.178000,0.183409,"10,832","933,414" 285 | "Jan 28, 2017",0.167891,0.191118,0.167889,0.185115,"12,342","845,152" 286 | "Jan 27, 2017",0.162051,0.242873,0.151854,0.167880,"24,828","814,864" 287 | "Jan 26, 2017",0.154363,0.179255,0.147483,0.161915,"9,966","775,361" 288 | "Jan 25, 2017",0.142849,0.313312,0.142811,0.154217,"14,945","716,763" 289 | "Jan 24, 2017",0.152959,0.671748,0.134264,0.142972,"33,237","766,670" 290 | "Jan 23, 2017",0.128182,0.156983,0.126968,0.154695,"6,921","641,762" 291 | "Jan 22, 2017",0.174903,0.178088,0.123697,0.128067,526,"874,666" 292 | "Jan 21, 2017",0.145710,0.236289,0.144554,0.174829,"12,872","727,753" 293 | "Jan 20, 2017",0.162671,0.166808,0.145625,0.145625,"5,978","812,236" 294 | -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/iota_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",0.371509,0.397608,0.362284,0.383096,"15,415,700","1,032,620,000" 3 | "Nov 06, 2017",0.351011,0.378777,0.338867,0.373939,"13,258,400","975,647,000" 4 | "Nov 05, 2017",0.367915,0.370910,0.335194,0.350084,"12,950,500","1,022,630,000" 5 | "Nov 04, 2017",0.391327,0.391546,0.365428,0.368643,"8,568,260","1,087,700,000" 6 | "Nov 03, 2017",0.362970,0.396015,0.358817,0.393126,"11,427,900","1,008,890,000" 7 | "Nov 02, 2017",0.370966,0.380213,0.320862,0.366056,"20,942,000","1,031,110,000" 8 | "Nov 01, 2017",0.390863,0.390863,0.356690,0.363920,"11,944,600","1,086,410,000" 9 | "Oct 31, 2017",0.407912,0.408340,0.390312,0.390915,"7,839,910","1,133,800,000" 10 | "Oct 30, 2017",0.403103,0.415571,0.385603,0.409046,"9,124,580","1,120,440,000" 11 | "Oct 29, 2017",0.395947,0.413541,0.367674,0.403720,"15,972,200","1,100,550,000" 12 | "Oct 28, 2017",0.424433,0.428173,0.391215,0.395483,"9,075,000","1,179,720,000" 13 | "Oct 27, 2017",0.416744,0.439441,0.395594,0.423355,"8,963,410","1,158,350,000" 14 | "Oct 26, 2017",0.443666,0.455887,0.411928,0.417107,"10,747,100","1,233,180,000" 15 | "Oct 25, 2017",0.455356,0.473467,0.430005,0.443448,"14,379,600","1,265,680,000" 16 | "Oct 24, 2017",0.389144,0.502278,0.377494,0.453682,"47,178,400","1,081,640,000" 17 | "Oct 23, 2017",0.391371,0.399234,0.364940,0.386487,"12,380,800","1,087,830,000" 18 | "Oct 22, 2017",0.390836,0.411999,0.381438,0.392542,"9,322,400","1,086,340,000" 19 | "Oct 21, 2017",0.403854,0.406504,0.324360,0.393045,"20,120,500","1,122,530,000" 20 | "Oct 20, 2017",0.432863,0.435639,0.391630,0.401913,"17,771,900","1,203,160,000" 21 | "Oct 19, 2017",0.457196,0.465953,0.415102,0.433388,"12,250,600","1,270,790,000" 22 | "Oct 18, 2017",0.474621,0.482291,0.427958,0.454575,"12,433,700","1,319,220,000" 23 | "Oct 17, 2017",0.452052,0.504408,0.434911,0.468463,"12,590,200","1,256,490,000" 24 | "Oct 16, 2017",0.439699,0.459618,0.423750,0.450655,"8,128,940","1,222,160,000" 25 | "Oct 15, 2017",0.458649,0.460506,0.414704,0.438429,"8,256,490","1,274,830,000" 26 | "Oct 14, 2017",0.441808,0.482837,0.431503,0.457837,"11,493,700","1,228,020,000" 27 | "Oct 13, 2017",0.412854,0.445985,0.403912,0.441595,"14,821,100","1,147,540,000" 28 | "Oct 12, 2017",0.481734,0.486223,0.391482,0.412417,"16,792,100","1,338,990,000" 29 | "Oct 11, 2017",0.477029,0.488967,0.464757,0.481464,"6,996,130","1,325,920,000" 30 | "Oct 10, 2017",0.466453,0.488517,0.452723,0.477576,"7,401,800","1,296,520,000" 31 | "Oct 09, 2017",0.500356,0.501909,0.439523,0.469438,"18,097,100","1,390,760,000" 32 | "Oct 08, 2017",0.534649,0.538526,0.492876,0.500032,"9,637,830","1,486,070,000" 33 | "Oct 07, 2017",0.504488,0.548719,0.490615,0.538529,"9,848,850","1,402,240,000" 34 | "Oct 06, 2017",0.543216,0.562671,0.493282,0.503448,"12,478,500","1,509,890,000" 35 | "Oct 05, 2017",0.547394,0.567734,0.520702,0.540915,"7,592,760","1,521,500,000" 36 | "Oct 04, 2017",0.560853,0.570545,0.520099,0.546982,"9,152,780","1,558,910,000" 37 | "Oct 03, 2017",0.577182,0.582044,0.516038,0.561712,"13,709,400","1,604,290,000" 38 | "Oct 02, 2017",0.618180,0.622090,0.565055,0.575398,"13,928,300","1,718,250,000" 39 | "Oct 01, 2017",0.621750,0.628776,0.592742,0.610183,"8,576,220","1,728,170,000" 40 | "Sep 30, 2017",0.584318,0.646884,0.576150,0.620822,"21,825,700","1,624,130,000" 41 | "Sep 29, 2017",0.595143,0.609587,0.543016,0.584418,"16,689,800","1,654,220,000" 42 | "Sep 28, 2017",0.549661,0.614313,0.528270,0.595896,"23,776,300","1,527,800,000" 43 | "Sep 27, 2017",0.514224,0.554709,0.507709,0.551005,"12,188,400","1,429,300,000" 44 | "Sep 26, 2017",0.556670,0.560043,0.507645,0.515205,"14,671,500","1,547,280,000" 45 | "Sep 25, 2017",0.524449,0.566395,0.524449,0.556207,"10,506,400","1,457,720,000" 46 | "Sep 24, 2017",0.540538,0.541688,0.506966,0.521379,"9,199,830","1,502,440,000" 47 | "Sep 23, 2017",0.507613,0.551145,0.494903,0.541796,"8,486,720","1,410,930,000" 48 | "Sep 22, 2017",0.499185,0.517458,0.476075,0.506010,"8,860,800","1,387,500,000" 49 | "Sep 21, 2017",0.567586,0.569993,0.467953,0.500724,"18,553,300","1,577,620,000" 50 | "Sep 20, 2017",0.559849,0.585680,0.543853,0.566627,"8,802,430","1,556,120,000" 51 | "Sep 19, 2017",0.608275,0.614231,0.555303,0.565168,"12,972,000","1,690,720,000" 52 | "Sep 18, 2017",0.496796,0.612485,0.496796,0.606233,"28,609,000","1,380,860,000" 53 | "Sep 17, 2017",0.484758,0.505875,0.462614,0.497046,"7,574,760","1,347,400,000" 54 | "Sep 16, 2017",0.479385,0.510361,0.453232,0.487239,"13,452,000","1,332,470,000" 55 | "Sep 15, 2017",0.445700,0.509332,0.372595,0.480510,"41,983,100","1,238,840,000" 56 | "Sep 14, 2017",0.565841,0.573630,0.445019,0.445019,"25,946,400","1,572,770,000" 57 | "Sep 13, 2017",0.592512,0.595366,0.479349,0.556820,"31,807,500","1,646,910,000" 58 | "Sep 12, 2017",0.561696,0.647193,0.557297,0.591949,"43,345,900","1,561,250,000" 59 | "Sep 11, 2017",0.498380,0.558273,0.481498,0.558273,"23,660,500","1,385,260,000" 60 | "Sep 10, 2017",0.561304,0.567870,0.462834,0.495607,"32,733,100","1,560,160,000" 61 | "Sep 09, 2017",0.525939,0.583964,0.524823,0.560809,"15,317,400","1,461,860,000" 62 | "Sep 08, 2017",0.648249,0.660258,0.490346,0.540475,"48,691,600","1,801,830,000" 63 | "Sep 07, 2017",0.739668,0.739668,0.622366,0.645758,"31,377,000","2,055,930,000" 64 | "Sep 06, 2017",0.613529,0.749172,0.601484,0.741663,"33,093,300","1,705,320,000" 65 | "Sep 05, 2017",0.544132,0.646085,0.468949,0.613085,"45,817,500","1,512,430,000" 66 | "Sep 04, 2017",0.744257,0.744257,0.406795,0.566472,"74,601,300","2,068,680,000" 67 | "Sep 03, 2017",0.698855,0.775863,0.672850,0.743968,"29,504,600","1,942,490,000" 68 | "Sep 02, 2017",0.796560,0.802464,0.658006,0.695547,"39,333,900","2,214,060,000" 69 | "Sep 01, 2017",0.842867,0.879100,0.768119,0.807778,"28,047,000","2,342,770,000" 70 | "Aug 31, 2017",0.869553,0.902074,0.828224,0.842424,"15,194,300","2,416,950,000" 71 | "Aug 30, 2017",0.812777,0.878203,0.792339,0.869647,"17,428,100","2,259,140,000" 72 | "Aug 29, 2017",0.876892,0.877578,0.746405,0.811961,"28,538,500","2,437,350,000" 73 | "Aug 28, 2017",0.922464,0.927742,0.784779,0.875197,"24,288,200","2,564,020,000" 74 | "Aug 27, 2017",0.962058,0.979088,0.887365,0.920351,"17,816,000","2,674,070,000" 75 | "Aug 26, 2017",0.915926,0.970068,0.877886,0.962213,"16,623,100","2,545,840,000" 76 | "Aug 25, 2017",0.894733,0.934651,0.837866,0.919635,"18,226,300","2,486,940,000" 77 | "Aug 24, 2017",0.854043,0.895101,0.813880,0.895101,"17,132,900","2,373,840,000" 78 | "Aug 23, 2017",0.842517,0.940389,0.834667,0.850371,"27,418,300","2,341,800,000" 79 | "Aug 22, 2017",0.901778,0.901778,0.786259,0.843775,"26,333,800","2,506,520,000" 80 | "Aug 21, 2017",0.907423,0.939166,0.843577,0.906269,"32,558,600","2,522,210,000" 81 | "Aug 20, 2017",0.971222,1.02,0.939619,0.942205,"29,447,600","2,699,540,000" 82 | "Aug 19, 2017",0.871580,0.985748,0.778133,0.978521,"39,975,500","2,422,580,000" 83 | "Aug 18, 2017",1.01,1.03,0.774400,0.870147,"58,053,400","2,819,080,000" 84 | "Aug 17, 2017",1.04,1.10,0.998241,1.02,"58,209,300","2,904,020,000" 85 | "Aug 16, 2017",0.914727,1.05,0.878567,1.05,"52,081,500","2,542,510,000" 86 | "Aug 15, 2017",0.977320,0.995791,0.767236,0.917949,"84,698,300","2,716,490,000" 87 | "Aug 14, 2017",0.811738,0.976404,0.793682,0.976404,"54,630,900","2,256,250,000" 88 | "Aug 13, 2017",0.722169,0.829530,0.715382,0.807713,"41,198,400","2,007,290,000" 89 | "Aug 12, 2017",0.655191,0.727960,0.625521,0.721535,"20,358,000","1,821,120,000" 90 | "Aug 11, 2017",0.565525,0.710585,0.557827,0.654872,"43,618,800","1,571,890,000" 91 | "Aug 10, 2017",0.535805,0.588071,0.513250,0.566456,"16,602,500","1,489,290,000" 92 | "Aug 09, 2017",0.547121,0.555125,0.512566,0.543328,"13,294,400","1,520,740,000" 93 | "Aug 08, 2017",0.473874,0.550880,0.458992,0.547637,"21,988,500","1,317,150,000" 94 | "Aug 07, 2017",0.430804,0.491028,0.418088,0.474577,"14,717,700","1,197,430,000" 95 | "Aug 06, 2017",0.407690,0.440193,0.396851,0.431142,"6,276,510","1,133,190,000" 96 | "Aug 05, 2017",0.393176,0.427798,0.364083,0.407980,"9,091,140","1,092,850,000" 97 | "Aug 04, 2017",0.332239,0.420252,0.332239,0.391286,"20,179,000","923,468,000" 98 | "Aug 03, 2017",0.286578,0.336844,0.284765,0.332352,"8,239,810","796,552,000" 99 | "Aug 02, 2017",0.290135,0.293039,0.272032,0.286116,"3,439,800","806,440,000" 100 | "Aug 01, 2017",0.256665,0.296267,0.249623,0.290220,"5,169,910","713,408,000" 101 | "Jul 31, 2017",0.255064,0.259810,0.245768,0.254732,"2,563,820","708,959,000" 102 | "Jul 30, 2017",0.277339,0.279401,0.252831,0.254785,"3,165,840","770,872,000" 103 | "Jul 29, 2017",0.266567,0.277226,0.245848,0.275190,"2,788,270","740,931,000" 104 | "Jul 28, 2017",0.274876,0.278459,0.262736,0.265118,"2,884,740","764,026,000" 105 | "Jul 27, 2017",0.276850,0.285551,0.275467,0.275467,"3,343,540","769,512,000" 106 | "Jul 26, 2017",0.250571,0.283478,0.241237,0.274598,"4,626,790","696,469,000" 107 | "Jul 25, 2017",0.266827,0.269072,0.237998,0.250453,"2,917,500","741,654,000" 108 | "Jul 24, 2017",0.265136,0.273468,0.242731,0.266447,"4,502,060","736,952,000" 109 | "Jul 23, 2017",0.273693,0.280241,0.258485,0.269072,"3,065,860","760,738,000" 110 | "Jul 22, 2017",0.263390,0.278936,0.254406,0.273382,"4,107,430","732,099,000" 111 | "Jul 21, 2017",0.294760,0.305506,0.257626,0.264134,"6,344,870","819,295,000" 112 | "Jul 20, 2017",0.233503,0.298253,0.232192,0.292460,"10,332,500","649,028,000" 113 | "Jul 19, 2017",0.268162,0.284031,0.230686,0.232212,"6,339,730","745,365,000" 114 | "Jul 18, 2017",0.264569,0.309577,0.248754,0.267340,"11,433,600","735,378,000" 115 | "Jul 17, 2017",0.180717,0.278088,0.179114,0.263105,"15,254,300","502,309,000" 116 | "Jul 16, 2017",0.157961,0.185445,0.155173,0.180978,"4,178,170","439,057,000" 117 | "Jul 15, 2017",0.175237,0.176099,0.147933,0.158688,"3,913,220","487,076,000" 118 | "Jul 14, 2017",0.212999,0.214112,0.161877,0.175350,"3,347,860","592,038,000" 119 | "Jul 13, 2017",0.229099,0.238625,0.194249,0.214589,"4,129,150","636,787,000" 120 | "Jul 12, 2017",0.191125,0.237362,0.183955,0.228758,"4,646,480","531,237,000" 121 | "Jul 11, 2017",0.214742,0.231574,0.185681,0.187596,"6,946,200","596,881,000" 122 | "Jul 10, 2017",0.304476,0.304476,0.190539,0.217061,"8,233,640","846,301,000" 123 | "Jul 09, 2017",0.297377,0.312770,0.285475,0.302889,"2,474,500","826,569,000" 124 | "Jul 08, 2017",0.286164,0.320908,0.281393,0.305515,"3,273,950","795,402,000" 125 | "Jul 07, 2017",0.355803,0.355994,0.271859,0.284565,"8,804,780","988,966,000" 126 | "Jul 06, 2017",0.380253,0.382865,0.317295,0.353880,"8,218,370","1,056,920,000" 127 | "Jul 05, 2017",0.396273,0.400841,0.371809,0.380130,"3,061,100","1,101,450,000" 128 | "Jul 04, 2017",0.374900,0.410698,0.373865,0.396390,"3,933,710","1,042,050,000" 129 | "Jul 03, 2017",0.379055,0.384955,0.356024,0.376139,"3,873,180","1,053,600,000" 130 | "Jul 02, 2017",0.391880,0.396890,0.366798,0.382249,"2,971,770","1,089,240,000" 131 | "Jul 01, 2017",0.402295,0.414192,0.381489,0.389630,"2,334,640","1,118,190,000" 132 | "Jun 30, 2017",0.417167,0.453008,0.398195,0.401591,"5,044,270","1,159,530,000" 133 | "Jun 29, 2017",0.375767,0.459387,0.361568,0.417798,"5,324,020","1,044,460,000" 134 | "Jun 28, 2017",0.399874,0.399874,0.357338,0.379136,"4,704,400","1,111,460,000" 135 | "Jun 27, 2017",0.411989,0.420035,0.353549,0.392269,"4,411,090","1,145,140,000" 136 | "Jun 26, 2017",0.470192,0.473662,0.351156,0.402438,"9,101,080","1,306,910,000" 137 | "Jun 25, 2017",0.514185,0.525564,0.454951,0.470941,"5,012,890","1,429,190,000" 138 | "Jun 24, 2017",0.482769,0.635612,0.482769,0.512910,"19,215,500","1,341,870,000" 139 | "Jun 23, 2017",0.417769,0.480910,0.408405,0.480910,"3,768,560","1,161,200,000" 140 | "Jun 22, 2017",0.413371,0.427283,0.407261,0.417742,"2,343,320","1,148,980,000" 141 | "Jun 21, 2017",0.419439,0.437340,0.405037,0.413547,"3,999,810","1,165,840,000" 142 | "Jun 20, 2017",0.414299,0.422032,0.398649,0.418494,"3,755,470","1,151,560,000" 143 | "Jun 19, 2017",0.405456,0.420990,0.388231,0.412183,"3,543,640","1,126,980,000" 144 | "Jun 18, 2017",0.420597,0.426069,0.393790,0.405862,"2,514,450","1,169,060,000" 145 | "Jun 17, 2017",0.426762,0.444205,0.414139,0.419906,"3,100,660","1,186,200,000" 146 | "Jun 16, 2017",0.353285,0.448249,0.309852,0.410757,"6,920,690","981,966,000" 147 | "Jun 15, 2017",0.528284,0.543165,0.300365,0.363661,"10,300,400","1,468,380,000" 148 | "Jun 14, 2017",0.592347,0.606196,0.495745,0.528916,"14,194,900","1,646,450,000" 149 | "Jun 13, 2017",0.638503,0.652862,0.533910,0.590255,"25,425,600","1,774,740,000" 150 | -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/jason_always_buy_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open 2 | "Nov 01, 2017",6.0 3 | "Nov 02, 2017",7.0 4 | "Nov 03, 2017",8.0 5 | "Nov 04, 2017",9.0 6 | "Nov 05, 2017",10.0 -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/jason_buy_sell_hold_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open 2 | "Nov 01, 2017",5.0 3 | "Nov 02, 2017",6.0 4 | "Nov 03, 2017",8.0 5 | "Nov 04, 2017",6.0 6 | "Nov 05, 2017",5.0 -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/jason_never_buy_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open 2 | "Nov 01, 2017",10.0 3 | "Nov 02, 2017",9.0 4 | "Nov 03, 2017",8.0 5 | "Nov 04, 2017",7.0 6 | "Nov 05, 2017",6.0 -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/numeraire_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",10.77,11.27,10.17,10.60,"121,944","13,444,500" 3 | "Nov 06, 2017",11.26,11.53,10.57,10.78,"57,204","14,062,200" 4 | "Nov 05, 2017",11.45,12.89,10.74,10.95,"185,214","14,298,300" 5 | "Nov 04, 2017",12.45,13.36,10.84,11.47,"334,820","15,548,300" 6 | "Nov 03, 2017",9.15,13.75,8.97,12.48,"482,650","11,423,500" 7 | "Nov 02, 2017",10.28,10.42,8.62,9.76,"205,052","12,832,100" 8 | "Nov 01, 2017",11.64,12.36,9.82,10.44,"230,197","14,534,400" 9 | "Oct 31, 2017",12.87,13.07,11.59,11.66,"163,423","16,067,000" 10 | "Oct 30, 2017",11.55,13.60,11.52,12.91,"178,535","14,416,700" 11 | "Oct 29, 2017",12.14,13.77,11.40,11.46,"259,423","15,160,800" 12 | "Oct 28, 2017",12.19,12.75,11.01,12.25,"148,762","15,218,000" 13 | "Oct 27, 2017",12.07,12.55,11.04,12.16,"139,761","15,071,400" 14 | "Oct 26, 2017",12.53,12.53,11.53,12.07,"65,175","15,647,800" 15 | "Oct 25, 2017",13.13,13.15,11.19,12.60,"77,863","16,393,000" 16 | "Oct 24, 2017",11.72,14.03,10.96,13.12,"118,312","14,637,400" 17 | "Oct 23, 2017",11.98,13.44,11.06,11.75,"115,467","14,957,400" 18 | "Oct 22, 2017",12.64,13.16,11.79,12.00,"50,124","15,788,900" 19 | "Oct 21, 2017",14.11,15.22,12.06,12.74,"129,563","17,616,500" 20 | "Oct 20, 2017",14.70,17.58,13.79,14.14,"434,935","18,349,500" 21 | "Oct 19, 2017",14.30,15.18,12.56,14.46,"209,523","17,851,900" 22 | "Oct 18, 2017",13.92,15.84,12.48,14.47,"356,003","17,384,800" 23 | "Oct 17, 2017",12.63,16.77,11.72,13.72,"480,549","15,775,200" 24 | "Oct 16, 2017",10.89,14.39,10.47,12.17,"332,447","13,599,700" 25 | "Oct 15, 2017",11.29,11.76,10.60,10.89,"64,751","14,102,400" 26 | "Oct 14, 2017",11.82,12.32,10.41,11.37,"228,223","14,754,900" 27 | "Oct 13, 2017",12.12,14.52,10.95,11.81,"518,327","15,127,600" 28 | "Oct 12, 2017",12.12,16.12,11.27,12.10,"945,572","15,128,000" 29 | "Oct 11, 2017",11.48,13.80,10.95,12.36,"205,337","14,343,600" 30 | "Oct 10, 2017",11.55,11.92,10.60,11.48,"112,363","14,430,000" 31 | "Oct 09, 2017",12.11,13.82,10.88,11.55,"184,017","15,121,100" 32 | "Oct 08, 2017",14.65,15.11,11.99,12.10,"256,490","18,293,100" 33 | "Oct 07, 2017",14.65,14.96,14.08,14.87,"145,223","18,295,100" 34 | "Oct 06, 2017",14.22,15.36,14.16,14.64,"91,720","17,754,300" 35 | "Oct 05, 2017",14.12,15.42,13.32,14.22,"220,070","17,635,900" 36 | "Oct 04, 2017",13.84,15.36,13.41,14.11,"240,893","17,295,800" 37 | "Oct 03, 2017",14.95,15.10,13.39,13.81,"149,112","18,683,000" 38 | "Oct 02, 2017",16.36,16.92,13.96,14.79,"467,244","20,440,100" 39 | "Oct 01, 2017",14.72,17.08,13.45,16.36,"298,959","18,394,200" 40 | "Sep 30, 2017",14.73,15.57,14.54,14.56,"69,376","18,409,000" 41 | "Sep 29, 2017",15.41,15.42,14.08,14.73,"135,492","19,254,500" 42 | "Sep 28, 2017",17.02,17.05,14.99,15.42,"125,586","21,268,800" 43 | "Sep 27, 2017",15.03,17.19,14.70,16.91,"277,008","18,785,600" 44 | "Sep 26, 2017",15.38,15.73,14.77,15.15,"143,434","19,222,600" 45 | "Sep 25, 2017",15.53,16.09,14.24,15.34,"287,753","19,416,300" 46 | "Sep 24, 2017",13.73,16.62,13.20,15.53,"686,526","17,157,200" 47 | "Sep 23, 2017",13.00,14.00,12.79,13.73,"124,841","16,252,500" 48 | "Sep 22, 2017",13.15,13.91,12.73,13.16,"55,768","16,441,500" 49 | "Sep 21, 2017",15.15,15.15,12.78,13.17,"170,853","18,936,100" 50 | "Sep 20, 2017",15.58,16.12,14.75,15.22,"160,192","19,478,000" 51 | "Sep 19, 2017",17.00,17.00,15.31,15.60,"149,142","21,252,800" 52 | "Sep 18, 2017",16.56,17.95,15.42,16.96,"219,636","20,703,500" 53 | "Sep 17, 2017",15.52,16.81,14.72,16.59,"74,804","19,409,800" 54 | "Sep 16, 2017",17.03,17.03,14.92,15.54,"106,754","21,290,500" 55 | "Sep 15, 2017",13.53,17.18,12.28,17.07,"229,961","16,919,700" 56 | "Sep 14, 2017",17.15,17.49,13.43,13.43,"208,388","21,435,700" 57 | "Sep 13, 2017",18.93,18.93,15.94,17.12,"311,553","23,673,000" 58 | "Sep 12, 2017",19.24,20.09,17.44,19.09,"398,928","24,063,900" 59 | "Sep 11, 2017",21.48,21.48,18.04,18.98,"335,702","26,868,700" 60 | "Sep 10, 2017",23.04,27.28,19.26,21.24,"1,448,320","28,821,700" 61 | "Sep 09, 2017",19.17,25.34,17.42,22.97,"1,345,530","23,977,600" 62 | "Sep 08, 2017",21.53,23.25,18.28,19.13,"305,855","26,935,100" 63 | "Sep 07, 2017",22.34,23.16,20.41,21.53,"262,532","27,947,600" 64 | "Sep 06, 2017",21.64,26.31,20.75,22.38,"473,273","27,076,900" 65 | "Sep 05, 2017",20.87,23.62,18.91,21.53,"349,885","26,115,800" 66 | "Sep 04, 2017",26.91,27.34,17.99,20.74,"716,231","33,673,500" 67 | "Sep 03, 2017",27.70,29.36,24.99,26.90,"493,926","34,662,300" 68 | "Sep 02, 2017",32.49,33.01,26.79,27.24,"633,861","40,658,600" 69 | "Sep 01, 2017",35.67,35.90,31.35,32.45,"1,024,920","44,636,600" 70 | "Aug 31, 2017",35.78,36.60,34.27,35.62,"452,411","44,776,600" 71 | "Aug 30, 2017",34.89,38.40,34.61,35.84,"549,569","43,694,000" 72 | "Aug 29, 2017",36.12,36.84,34.43,34.92,"489,247","45,236,000" 73 | "Aug 28, 2017",35.56,36.20,34.11,36.07,"402,594","44,537,800" 74 | "Aug 27, 2017",35.16,36.33,34.05,35.53,"372,296","44,033,500" 75 | "Aug 26, 2017",35.31,37.01,33.54,34.93,"363,769","44,220,200" 76 | "Aug 25, 2017",35.51,37.67,32.94,35.24,"845,188","44,468,400" 77 | "Aug 24, 2017",35.60,37.29,34.84,35.39,"466,415","44,577,800" 78 | "Aug 23, 2017",35.53,38.34,34.85,36.49,"443,443","44,506,600" 79 | "Aug 22, 2017",34.75,37.23,31.91,35.61,"561,611","43,526,300" 80 | "Aug 21, 2017",42.41,48.73,33.48,34.58,"2,145,180","53,121,100" 81 | "Aug 20, 2017",34.73,43.36,32.52,42.53,"1,894,140","43,499,200" 82 | "Aug 19, 2017",35.56,37.01,31.60,34.84,"582,704","44,542,600" 83 | "Aug 18, 2017",34.17,39.43,31.88,35.03,"1,612,640","42,797,100" 84 | "Aug 17, 2017",33.79,36.14,31.85,33.92,"739,864","42,325,000" 85 | "Aug 16, 2017",31.27,37.92,30.37,33.62,"864,797","39,176,900" 86 | "Aug 15, 2017",34.85,36.10,30.67,31.23,"763,238","43,659,400" 87 | "Aug 14, 2017",36.80,38.09,32.76,34.65,"763,860","46,104,500" 88 | "Aug 13, 2017",43.83,46.78,33.13,36.78,"1,431,600","54,913,000" 89 | "Aug 12, 2017",34.64,47.85,32.80,43.37,"2,680,510","43,392,300" 90 | "Aug 11, 2017",26.46,41.47,26.06,33.64,"3,202,390","33,143,700" 91 | "Aug 10, 2017",28.84,29.21,26.46,26.46,"748,370","36,136,200" 92 | "Aug 09, 2017",27.96,33.04,26.79,29.24,"1,128,830","35,034,100" 93 | "Aug 08, 2017",27.86,28.34,25.22,27.97,"521,900","34,067,900" 94 | "Aug 07, 2017",28.32,30.01,26.70,27.93,"456,117","34,625,700" 95 | "Aug 06, 2017",29.42,29.76,27.60,28.38,"386,351","35,980,100" 96 | "Aug 05, 2017",26.66,30.41,26.59,29.25,"558,040","32,606,100" 97 | "Aug 04, 2017",26.80,28.27,26.47,26.63,"403,184","32,772,500" 98 | "Aug 03, 2017",26.26,28.38,25.59,27.17,"320,060","32,107,700" 99 | "Aug 02, 2017",26.15,29.96,24.75,26.23,"551,211","31,986,000" 100 | "Aug 01, 2017",25.65,30.04,24.18,26.17,"305,623","31,374,200" 101 | "Jul 31, 2017",26.01,26.47,24.69,25.28,"166,615","31,810,000" 102 | "Jul 30, 2017",25.88,27.32,24.76,26.51,"116,912","31,649,900" 103 | "Jul 29, 2017",25.28,26.29,24.13,25.87,"120,964","30,920,300" 104 | "Jul 28, 2017",27.72,28.26,24.15,25.37,"214,957","33,899,000" 105 | "Jul 27, 2017",27.48,28.43,26.25,27.64,"163,616","33,610,800" 106 | "Jul 26, 2017",27.65,28.93,24.75,26.97,"323,792","33,814,100" 107 | "Jul 25, 2017",33.69,33.89,25.92,27.29,"460,800","41,210,000" 108 | "Jul 24, 2017",33.01,36.16,32.04,33.69,"551,830","40,370,800" 109 | "Jul 23, 2017",36.59,37.54,32.41,32.89,"515,553","44,748,100" 110 | "Jul 22, 2017",34.14,41.15,33.96,36.59,"909,922","41,751,100" 111 | "Jul 21, 2017",35.87,38.40,33.27,34.14,"320,166","43,866,500" 112 | "Jul 20, 2017",27.93,39.44,26.73,35.54,"1,116,080","34,174,900" 113 | "Jul 19, 2017",25.08,35.93,23.53,28.23,"1,959,790","30,689,100" 114 | "Jul 18, 2017",23.11,29.48,20.47,25.31,"550,981","28,272,600" 115 | "Jul 17, 2017",17.46,22.79,17.46,22.69,"272,026","21,363,400" 116 | "Jul 16, 2017",18.99,20.06,16.54,17.49,"213,544","23,236,900" 117 | "Jul 15, 2017",23.20,23.24,18.69,19.05,"269,653","28,383,800" 118 | "Jul 14, 2017",26.80,27.67,21.18,23.24,"424,550","32,787,700" 119 | "Jul 13, 2017",30.83,31.24,25.64,26.82,"453,602","37,715,200" 120 | "Jul 12, 2017",20.32,32.90,18.75,30.71,"1,538,890","24,856,500" 121 | "Jul 11, 2017",23.53,26.49,18.33,20.73,"613,446","28,787,300" 122 | "Jul 10, 2017",28.65,31.54,20.99,24.04,"678,731","35,055,400" 123 | "Jul 09, 2017",27.54,30.14,26.83,28.29,"576,144","33,695,700" 124 | "Jul 08, 2017",28.99,30.77,23.66,27.51,"860,141","35,465,600" 125 | "Jul 07, 2017",36.08,36.88,25.44,29.39,"1,277,090","44,138,900" 126 | "Jul 06, 2017",38.60,39.21,32.20,35.79,"1,538,390","47,227,600" 127 | "Jul 05, 2017",39.39,41.59,37.64,39.03,"829,545","48,195,200" 128 | "Jul 04, 2017",41.60,43.46,37.38,39.42,"1,917,540","50,895,200" 129 | "Jul 03, 2017",43.17,46.92,41.41,41.69,"1,348,590","52,810,600" 130 | "Jul 02, 2017",43.12,54.01,39.95,42.87,"3,610,660","52,749,500" 131 | "Jul 01, 2017",34.19,68.93,33.29,45.26,"12,854,500","41,835,200" 132 | "Jun 30, 2017",42.26,43.96,29.13,34.20,"4,824,820","51,703,800" 133 | "Jun 29, 2017",53.26,53.26,38.82,42.89,"3,130,230","65,159,400" 134 | "Jun 28, 2017",51.92,58.38,46.21,53.07,"4,397,750","63,517,500" 135 | "Jun 27, 2017",59.82,62.31,36.29,53.05,"6,824,330","73,191,200" 136 | "Jun 26, 2017",88.17,98.78,49.70,59.90,"9,639,820","107,875,000" 137 | "Jun 25, 2017",103.21,168.49,72.49,86.55,"34,331,400","126,269,000" 138 | "Jun 24, 2017",44.48,116.40,42.04,101.83,"17,322,100","54,422,400" 139 | "Jun 23, 2017",35.05,48.58,17.67,45.63,"4,354,180",- 140 | -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/omisego_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",6.52,6.67,6.16,6.33,"17,428,900","665,398,000" 3 | "Nov 06, 2017",6.28,6.68,6.22,6.48,"21,223,900","617,414,000" 4 | "Nov 05, 2017",6.44,6.49,6.17,6.29,"12,819,400","633,214,000" 5 | "Nov 04, 2017",6.72,6.77,6.38,6.45,"16,963,100","660,838,000" 6 | "Nov 03, 2017",6.23,6.78,6.15,6.73,"27,548,300","612,383,000" 7 | "Nov 02, 2017",6.05,6.67,5.55,6.23,"55,264,500","594,839,000" 8 | "Nov 01, 2017",6.83,6.96,6.05,6.05,"37,953,700","671,068,000" 9 | "Oct 31, 2017",7.23,7.29,6.84,6.84,"21,797,300","710,488,000" 10 | "Oct 30, 2017",7.28,7.40,7.13,7.25,"14,224,900","715,973,000" 11 | "Oct 29, 2017",7.16,7.44,7.15,7.30,"18,076,000","703,486,000" 12 | "Oct 28, 2017",7.49,7.54,7.17,7.18,"17,242,600","736,331,000" 13 | "Oct 27, 2017",7.65,8.12,7.42,7.46,"28,704,900","751,745,000" 14 | "Oct 26, 2017",7.66,7.80,7.48,7.65,"19,134,300","752,636,000" 15 | "Oct 25, 2017",8.12,8.14,7.56,7.62,"20,363,000","798,130,000" 16 | "Oct 24, 2017",7.59,8.70,7.38,8.13,"54,151,300","746,181,000" 17 | "Oct 23, 2017",7.65,7.66,7.12,7.61,"17,684,200","752,139,000" 18 | "Oct 22, 2017",7.37,7.78,7.36,7.67,"19,588,000","724,177,000" 19 | "Oct 21, 2017",7.31,7.46,6.99,7.37,"19,448,800","718,401,000" 20 | "Oct 20, 2017",7.90,7.91,7.29,7.31,"20,554,400","776,825,000" 21 | "Oct 19, 2017",7.82,8.08,7.68,7.92,"14,064,200","769,045,000" 22 | "Oct 18, 2017",7.97,8.08,7.66,7.84,"20,915,200","783,502,000" 23 | "Oct 17, 2017",7.86,8.24,7.69,7.99,"23,177,500","772,486,000" 24 | "Oct 16, 2017",8.00,8.10,7.60,7.85,"19,951,300","786,681,000" 25 | "Oct 15, 2017",8.03,8.24,7.67,7.97,"23,508,300","789,379,000" 26 | "Oct 14, 2017",8.31,8.38,7.99,8.03,"20,284,600","816,802,000" 27 | "Oct 13, 2017",8.19,8.68,7.98,8.30,"33,908,900","805,549,000" 28 | "Oct 12, 2017",9.26,9.53,8.18,8.20,"49,996,900","910,544,000" 29 | "Oct 11, 2017",8.12,9.42,8.12,9.26,"57,741,200","798,713,000" 30 | "Oct 10, 2017",7.49,8.39,7.28,8.09,"27,542,200","736,231,000" 31 | "Oct 09, 2017",7.78,8.10,7.03,7.50,"34,823,600","765,067,000" 32 | "Oct 08, 2017",8.54,8.61,7.62,7.70,"27,120,900","839,543,000" 33 | "Oct 07, 2017",8.66,8.69,8.14,8.54,"18,207,700","851,803,000" 34 | "Oct 06, 2017",8.82,8.89,8.49,8.66,"13,957,500","866,972,000" 35 | "Oct 05, 2017",8.67,8.97,8.23,8.80,"19,715,100","852,239,000" 36 | "Oct 04, 2017",9.26,9.27,8.60,8.66,"19,933,100","909,963,000" 37 | "Oct 03, 2017",9.19,9.27,8.53,9.24,"35,595,500","903,903,000" 38 | "Oct 02, 2017",9.82,9.99,9.07,9.20,"36,673,900","965,225,000" 39 | "Oct 01, 2017",10.11,10.15,9.57,9.82,"21,494,500","994,233,000" 40 | "Sep 30, 2017",9.74,10.27,9.68,10.12,"26,871,400","957,899,000" 41 | "Sep 29, 2017",10.47,10.58,9.19,9.75,"51,306,900","1,029,050,000" 42 | "Sep 28, 2017",10.35,11.48,10.07,10.49,"66,693,200","1,017,090,000" 43 | "Sep 27, 2017",9.78,10.52,9.77,10.34,"38,915,800","961,863,000" 44 | "Sep 26, 2017",10.01,10.27,9.69,9.76,"26,920,700","984,356,000" 45 | "Sep 25, 2017",8.66,10.38,8.63,10.00,"59,857,600","851,863,000" 46 | "Sep 24, 2017",9.01,9.12,8.53,8.66,"19,730,500","885,388,000" 47 | "Sep 23, 2017",8.66,9.36,8.43,9.03,"28,436,100","851,587,000" 48 | "Sep 22, 2017",8.13,8.96,7.93,8.65,"42,277,500","799,239,000" 49 | "Sep 21, 2017",9.12,9.39,7.75,8.12,"51,911,500","897,056,000" 50 | "Sep 20, 2017",9.92,9.95,9.11,9.11,"36,072,700","975,691,000" 51 | "Sep 19, 2017",11.00,11.03,9.68,9.92,"38,392,200","1,081,420,000" 52 | "Sep 18, 2017",9.88,11.34,9.88,10.98,"54,086,300","971,499,000" 53 | "Sep 17, 2017",9.90,10.31,8.98,9.87,"40,154,600","973,696,000" 54 | "Sep 16, 2017",9.96,10.65,9.34,9.93,"66,155,100","979,204,000" 55 | "Sep 15, 2017",8.13,10.39,6.57,9.95,"156,528,000","798,813,000" 56 | "Sep 14, 2017",10.58,11.06,7.67,8.08,"95,558,500","1,040,220,000" 57 | "Sep 13, 2017",11.68,11.70,9.55,10.61,"85,896,500","1,148,450,000" 58 | "Sep 12, 2017",11.37,13.45,11.21,11.59,"130,591,000","1,117,370,000" 59 | "Sep 11, 2017",11.42,11.98,11.09,11.33,"37,733,800","1,122,960,000" 60 | "Sep 10, 2017",12.29,12.29,10.76,11.40,"53,265,800","1,207,860,000" 61 | "Sep 09, 2017",11.38,12.22,10.88,12.22,"63,245,300","1,118,990,000" 62 | "Sep 08, 2017",12.91,13.39,10.66,11.45,"99,091,800","1,268,790,000" 63 | "Sep 07, 2017",11.65,13.53,10.77,12.87,"153,192,000","1,145,440,000" 64 | "Sep 06, 2017",10.96,11.79,10.49,11.64,"95,001,000","1,077,300,000" 65 | "Sep 05, 2017",8.68,11.28,7.60,10.98,"111,430,000","852,870,000" 66 | "Sep 04, 2017",10.55,10.55,7.31,8.78,"159,979,000","1,037,440,000" 67 | "Sep 03, 2017",10.79,11.37,9.64,10.57,"68,616,800","1,060,760,000" 68 | "Sep 02, 2017",11.99,11.99,9.96,10.80,"93,561,000","1,178,610,000" 69 | "Sep 01, 2017",11.73,12.52,11.63,11.97,"91,962,400","1,153,390,000" 70 | "Aug 31, 2017",11.17,12.08,10.78,11.74,"89,710,200","1,098,470,000" 71 | "Aug 30, 2017",9.49,11.67,9.30,11.07,"194,613,000","932,958,000" 72 | "Aug 29, 2017",8.58,9.62,8.45,9.46,"86,155,000","843,249,000" 73 | "Aug 28, 2017",8.33,8.93,8.15,8.59,"52,390,300","819,005,000" 74 | "Aug 27, 2017",8.29,8.37,8.03,8.33,"22,915,000","815,412,000" 75 | "Aug 26, 2017",8.26,8.33,7.85,8.28,"25,661,900","812,289,000" 76 | "Aug 25, 2017",8.38,8.46,8.04,8.27,"24,205,300","823,620,000" 77 | "Aug 24, 2017",8.20,8.39,7.97,8.37,"31,284,200","806,267,000" 78 | "Aug 23, 2017",7.61,8.66,7.58,8.24,"64,455,600","748,515,000" 79 | "Aug 22, 2017",7.67,7.76,6.96,7.62,"41,423,400","753,880,000" 80 | "Aug 21, 2017",8.45,8.60,7.34,7.67,"71,569,400","830,536,000" 81 | "Aug 20, 2017",7.76,8.84,7.17,8.44,"74,687,700","762,542,000" 82 | "Aug 19, 2017",7.31,7.93,6.42,7.80,"70,997,400","718,510,000" 83 | "Aug 18, 2017",8.40,8.45,6.32,7.34,"104,224,000","825,591,000" 84 | "Aug 17, 2017",8.89,9.47,8.29,8.40,"131,488,000","873,548,000" 85 | "Aug 16, 2017",6.67,9.02,6.67,8.87,"204,580,000","655,537,000" 86 | "Aug 15, 2017",6.94,7.05,6.16,6.69,"67,045,700","682,506,000" 87 | "Aug 14, 2017",6.88,7.38,6.25,7.02,"85,191,300","676,804,000" 88 | "Aug 13, 2017",6.18,7.53,5.36,6.94,"128,909,000","607,772,000" 89 | "Aug 12, 2017",7.20,7.40,5.83,6.19,"87,590,300","707,779,000" 90 | "Aug 11, 2017",5.96,7.81,5.41,7.23,"200,287,000","586,021,000" 91 | "Aug 10, 2017",3.41,6.36,3.38,5.93,"234,693,000","335,183,000" 92 | "Aug 09, 2017",3.62,3.68,3.26,3.45,"24,783,900","355,440,000" 93 | "Aug 08, 2017",3.15,3.76,3.07,3.61,"49,778,700","309,766,000" 94 | "Aug 07, 2017",2.70,3.25,2.63,3.15,"34,417,900","265,138,000" 95 | "Aug 06, 2017",3.62,3.62,2.59,2.75,"39,669,900","356,183,000" 96 | "Aug 05, 2017",2.79,3.73,2.74,3.61,"95,593,700","274,109,000" 97 | "Aug 04, 2017",1.95,2.79,1.94,2.76,"44,051,500","192,003,000" 98 | "Aug 03, 2017",1.38,2.03,1.37,1.96,"18,348,800","135,528,000" 99 | "Aug 02, 2017",1.34,1.39,1.29,1.38,"3,708,080","131,707,000" 100 | "Aug 01, 2017",1.22,1.37,1.18,1.33,"4,360,060","120,415,000" 101 | "Jul 31, 2017",1.20,1.26,1.17,1.23,"2,153,100","118,309,000" 102 | "Jul 30, 2017",1.27,1.31,1.19,1.21,"1,749,290","124,645,000" 103 | "Jul 29, 2017",1.19,1.29,1.11,1.28,"2,651,230","116,968,000" 104 | "Jul 28, 2017",1.38,1.39,1.12,1.19,"5,438,700","135,475,000" 105 | "Jul 27, 2017",1.21,1.41,1.20,1.38,"5,379,280","118,718,000" 106 | "Jul 26, 2017",1.23,1.29,1.10,1.21,"4,740,910","121,110,000" 107 | "Jul 25, 2017",1.53,1.55,1.12,1.23,"8,132,390","150,667,000" 108 | "Jul 24, 2017",1.51,1.61,1.31,1.52,"12,526,000","148,581,000" 109 | "Jul 23, 2017",0.878973,1.59,0.850754,1.53,"15,198,100","86,413,600" 110 | "Jul 22, 2017",0.742038,0.886832,0.739422,0.878662,"3,596,130","72,951,200" 111 | "Jul 21, 2017",0.669754,0.786582,0.632858,0.753032,"2,140,420","65,844,800" 112 | "Jul 20, 2017",0.596119,0.717632,0.596119,0.659447,"3,376,440","58,605,700" 113 | "Jul 19, 2017",0.759290,0.797288,0.568905,0.583911,"4,236,020","74,647,300" 114 | "Jul 18, 2017",0.574224,0.894874,0.565539,0.759819,"8,394,650","56,453,100" 115 | "Jul 17, 2017",0.381684,0.598633,0.379345,0.582786,"4,273,090","37,524,100" 116 | "Jul 16, 2017",0.431081,0.494342,0.319695,0.384906,"1,743,630","42,380,400" 117 | "Jul 15, 2017",0.586446,0.652156,0.433351,0.433351,"1,552,730",- 118 | "Jul 14, 2017",0.534731,0.775406,0.500232,0.582480,"750,698",- 119 | -------------------------------------------------------------------------------- /v1/cryptocurrencypricehistory/qtum_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",10.32,11.45,10.32,11.21,"122,951,000","760,320,000" 3 | "Nov 06, 2017",10.13,11.18,10.06,10.44,"116,937,000","745,802,000" 4 | "Nov 05, 2017",10.04,10.43,9.96,10.13,"49,288,500","739,113,000" 5 | "Nov 04, 2017",10.31,10.40,9.82,10.05,"35,477,100","759,110,000" 6 | "Nov 03, 2017",9.77,10.42,9.70,10.38,"55,018,600","719,701,000" 7 | "Nov 02, 2017",9.95,10.04,9.35,9.80,"54,501,600","732,691,000" 8 | "Nov 01, 2017",10.41,10.41,9.92,9.93,"26,591,700","766,698,000" 9 | "Oct 31, 2017",10.38,10.88,10.35,10.45,"43,306,600","764,029,000" 10 | "Oct 30, 2017",10.39,10.48,10.29,10.39,"21,781,900","765,031,000" 11 | "Oct 29, 2017",10.19,10.54,10.18,10.42,"40,119,600","750,443,000" 12 | "Oct 28, 2017",10.33,10.38,10.18,10.21,"23,588,200","760,135,000" 13 | "Oct 27, 2017",10.56,10.63,10.26,10.30,"27,344,700","777,594,000" 14 | "Oct 26, 2017",10.66,10.79,10.45,10.57,"26,461,700","784,784,000" 15 | "Oct 25, 2017",10.78,10.92,10.37,10.65,"48,104,100","793,779,000" 16 | "Oct 24, 2017",9.96,11.46,9.52,10.76,"118,813,000","733,399,000" 17 | "Oct 23, 2017",10.59,10.60,9.75,9.96,"50,654,800","779,244,000" 18 | "Oct 22, 2017",10.97,11.06,10.56,10.63,"33,890,300","807,214,000" 19 | "Oct 21, 2017",11.25,11.35,10.50,10.91,"56,075,000","828,306,000" 20 | "Oct 20, 2017",12.10,15.12,11.19,11.30,"304,281,000","890,682,000" 21 | "Oct 19, 2017",11.46,12.22,11.35,12.07,"49,308,300","688,986,000" 22 | "Oct 18, 2017",12.04,12.04,10.78,11.49,"53,960,300","710,326,000" 23 | "Oct 17, 2017",11.48,12.27,11.03,12.05,"57,046,400","677,311,000" 24 | "Oct 16, 2017",10.46,11.65,10.23,11.49,"37,568,400","616,895,000" 25 | "Oct 15, 2017",10.64,10.66,10.09,10.44,"22,057,700","627,948,000" 26 | "Oct 14, 2017",11.26,11.45,10.62,10.63,"17,709,400","664,129,000" 27 | "Oct 13, 2017",11.30,11.30,10.31,11.25,"44,760,500","666,714,000" 28 | "Oct 12, 2017",12.13,12.21,11.29,11.29,"31,335,300","715,782,000" 29 | "Oct 11, 2017",12.04,12.29,11.87,12.13,"28,771,600","710,230,000" 30 | "Oct 10, 2017",12.04,12.54,11.55,12.08,"50,232,800","710,536,000" 31 | "Oct 09, 2017",11.14,12.49,10.96,12.07,"57,974,000","657,304,000" 32 | "Oct 08, 2017",11.96,12.11,11.14,11.14,"34,305,900","705,791,000" 33 | "Oct 07, 2017",11.67,11.94,11.51,11.94,"19,498,800","688,284,000" 34 | "Oct 06, 2017",11.87,11.91,11.50,11.69,"23,341,500","700,544,000" 35 | "Oct 05, 2017",11.60,11.98,10.82,11.86,"67,610,800","684,358,000" 36 | "Oct 04, 2017",12.16,12.28,11.51,11.63,"77,387,000","717,223,000" 37 | "Oct 03, 2017",11.91,12.12,10.78,12.12,"95,756,400","702,872,000" 38 | "Oct 02, 2017",12.36,12.38,11.43,11.88,"69,789,000","729,062,000" 39 | "Oct 01, 2017",11.59,12.61,11.58,12.34,"162,762,000","683,566,000" 40 | "Sep 30, 2017",9.77,11.65,9.75,11.59,"141,320,000","576,371,000" 41 | "Sep 29, 2017",9.96,10.00,9.15,9.77,"79,526,300","587,845,000" 42 | "Sep 28, 2017",9.95,10.10,9.06,9.93,"95,333,300","586,983,000" 43 | "Sep 27, 2017",9.37,9.90,9.35,9.90,"59,847,700","552,811,000" 44 | "Sep 26, 2017",9.38,10.30,9.17,9.34,"104,988,000","553,598,000" 45 | "Sep 25, 2017",8.03,9.60,8.03,9.36,"82,385,100","473,818,000" 46 | "Sep 24, 2017",8.10,8.28,7.79,8.04,"28,266,800","477,945,000" 47 | "Sep 23, 2017",7.70,8.21,7.48,8.11,"40,760,800","454,162,000" 48 | "Sep 22, 2017",7.34,7.91,7.27,7.68,"42,861,600","433,000,000" 49 | "Sep 21, 2017",8.77,8.81,7.34,7.38,"38,239,000","517,612,000" 50 | "Sep 20, 2017",8.92,9.05,8.47,8.79,"38,916,900","526,414,000" 51 | "Sep 19, 2017",9.65,9.70,8.75,8.91,"66,250,600","569,633,000" 52 | "Sep 18, 2017",8.31,10.51,8.31,9.62,"167,586,000","490,417,000" 53 | "Sep 17, 2017",8.19,8.79,7.59,8.27,"69,847,200","482,927,000" 54 | "Sep 16, 2017",8.49,8.97,7.44,8.25,"97,992,200","500,809,000" 55 | "Sep 15, 2017",7.72,9.31,5.91,8.47,"242,984,000","455,212,000" 56 | "Sep 14, 2017",11.94,12.18,7.60,7.60,"137,040,000","704,415,000" 57 | "Sep 13, 2017",13.45,13.53,11.60,11.94,"185,348,000","793,825,000" 58 | "Sep 12, 2017",14.38,15.31,12.86,13.51,"156,187,000","848,364,000" 59 | "Sep 11, 2017",12.64,14.79,12.55,14.28,"165,283,000","745,787,000" 60 | "Sep 10, 2017",13.27,13.34,11.38,12.78,"172,687,000","783,150,000" 61 | "Sep 09, 2017",13.40,13.63,12.46,13.32,"99,008,100","790,322,000" 62 | "Sep 08, 2017",14.74,16.07,12.44,13.50,"294,169,000","869,878,000" 63 | "Sep 07, 2017",11.40,14.77,10.69,14.74,"195,986,000","672,888,000" 64 | "Sep 06, 2017",11.73,12.49,10.34,11.40,"141,347,000","691,921,000" 65 | "Sep 05, 2017",11.07,12.07,8.77,11.71,"218,917,000","653,177,000" 66 | "Sep 04, 2017",15.29,15.44,10.22,10.98,"161,203,000","902,407,000" 67 | "Sep 03, 2017",16.41,16.74,14.19,15.29,"98,105,400","967,971,000" 68 | "Sep 02, 2017",18.26,19.06,15.51,16.39,"123,479,000","1,077,370,000" 69 | "Sep 01, 2017",17.30,18.47,16.94,18.26,"73,618,500","1,020,980,000" 70 | "Aug 31, 2017",16.72,18.08,16.69,17.30,"76,872,500","986,295,000" 71 | "Aug 30, 2017",19.05,19.05,14.58,16.84,"145,512,000","1,124,200,000" 72 | "Aug 29, 2017",16.28,20.04,16.28,19.15,"216,784,000","960,486,000" 73 | "Aug 28, 2017",15.66,16.35,14.86,16.24,"82,850,200","923,722,000" 74 | "Aug 27, 2017",15.42,15.86,14.74,15.70,"56,474,400","909,788,000" 75 | "Aug 26, 2017",13.26,15.89,12.97,15.41,"88,172,500","782,374,000" 76 | "Aug 25, 2017",13.75,13.85,12.85,13.32,"26,327,100","811,035,000" 77 | "Aug 24, 2017",11.87,14.13,11.64,13.78,"72,955,500","700,167,000" 78 | "Aug 23, 2017",11.05,12.47,11.04,11.90,"36,722,000","651,839,000" 79 | "Aug 22, 2017",11.20,11.41,10.17,11.06,"25,086,300","660,585,000" 80 | "Aug 21, 2017",11.80,11.87,10.82,11.23,"29,380,800","696,434,000" 81 | "Aug 20, 2017",11.54,12.35,10.82,11.79,"40,638,800","680,885,000" 82 | "Aug 19, 2017",11.62,12.36,9.69,11.64,"54,327,300","685,316,000" 83 | "Aug 18, 2017",13.09,13.09,11.00,11.63,"43,226,400","772,302,000" 84 | "Aug 17, 2017",14.36,14.37,12.82,13.06,"50,489,100","847,017,000" 85 | "Aug 16, 2017",14.67,15.42,14.15,14.35,"59,126,000","865,463,000" 86 | "Aug 15, 2017",15.01,15.30,13.83,14.68,"62,353,100","885,415,000" 87 | "Aug 14, 2017",15.10,17.16,14.36,15.06,"103,750,000","890,836,000" 88 | "Aug 13, 2017",13.92,15.84,12.79,15.17,"75,650,500","821,280,000" 89 | "Aug 12, 2017",14.73,15.47,12.85,13.90,"59,321,200","868,962,000" 90 | "Aug 11, 2017",15.63,16.36,14.33,14.73,"91,215,900","922,433,000" 91 | "Aug 10, 2017",12.55,16.99,12.42,15.77,"133,259,000","740,715,000" 92 | "Aug 09, 2017",11.49,12.63,11.07,12.55,"52,016,000","677,866,000" 93 | "Aug 08, 2017",12.64,12.74,10.84,11.50,"63,155,600","746,010,000" 94 | "Aug 07, 2017",10.03,12.84,9.88,12.65,"95,630,200","591,790,000" 95 | "Aug 06, 2017",9.34,10.83,9.08,10.07,"54,977,800","550,855,000" 96 | "Aug 05, 2017",8.22,9.52,7.80,9.38,"42,482,900","484,803,000" 97 | "Aug 04, 2017",7.68,8.71,7.68,8.22,"31,879,600","452,969,000" 98 | "Aug 03, 2017",6.42,7.86,6.17,7.65,"30,278,900","378,741,000" 99 | "Aug 02, 2017",6.56,6.69,6.32,6.43,"11,978,000","387,234,000" 100 | "Aug 01, 2017",6.12,6.67,5.74,6.49,"20,864,300","361,165,000" 101 | "Jul 31, 2017",5.53,6.36,5.43,6.12,"13,123,400","326,029,000" 102 | "Jul 30, 2017",5.77,5.84,5.46,5.53,"3,168,030","340,554,000" 103 | "Jul 29, 2017",5.80,5.86,5.38,5.78,"5,188,990","342,217,000" 104 | "Jul 28, 2017",6.23,6.31,5.74,5.75,"7,599,310","367,403,000" 105 | "Jul 27, 2017",6.29,6.42,6.02,6.21,"10,757,800","370,867,000" 106 | "Jul 26, 2017",6.14,6.49,5.28,6.26,"20,824,500","362,203,000" 107 | "Jul 25, 2017",7.31,7.61,5.68,6.13,"22,782,500","372,639,000" 108 | "Jul 24, 2017",6.67,7.30,6.46,7.26,"12,601,300","339,927,000" 109 | "Jul 23, 2017",7.55,7.62,6.14,6.64,"23,752,700","385,277,000" 110 | "Jul 22, 2017",7.81,7.99,7.48,7.52,"16,650,500","398,441,000" 111 | "Jul 21, 2017",7.84,9.15,7.01,7.84,"48,210,600","399,824,000" 112 | "Jul 20, 2017",5.69,7.68,5.69,7.59,"33,148,900","289,993,000" 113 | "Jul 19, 2017",5.18,6.62,4.79,5.62,"29,526,300","264,087,000" 114 | "Jul 18, 2017",4.41,5.35,4.27,5.18,"16,788,400","224,792,000" 115 | "Jul 17, 2017",3.91,4.47,3.91,4.38,"7,531,300","199,276,000" 116 | "Jul 16, 2017",3.93,4.24,3.71,3.93,"5,467,430","200,412,000" 117 | "Jul 15, 2017",4.54,4.55,3.86,3.88,"6,403,170","231,785,000" 118 | "Jul 14, 2017",5.11,5.18,4.47,4.53,"6,385,700","260,726,000" 119 | "Jul 13, 2017",5.65,6.12,5.02,5.11,"8,076,010","288,266,000" 120 | "Jul 12, 2017",4.67,5.69,4.36,5.59,"11,808,500",- 121 | "Jul 11, 2017",5.23,5.42,3.89,4.82,"11,515,200",- 122 | "Jul 10, 2017",6.42,6.75,5.03,5.38,"5,648,270",- 123 | "Jul 09, 2017",6.91,7.58,6.35,6.36,"6,985,260",- 124 | "Jul 08, 2017",6.90,7.11,5.64,6.86,"12,481,200",- 125 | "Jul 07, 2017",8.73,8.75,6.67,6.87,"7,176,910",- 126 | "Jul 06, 2017",8.44,9.35,7.95,8.75,"13,670,300",- 127 | "Jul 05, 2017",9.33,9.33,7.96,8.30,"8,151,290",- 128 | "Jul 04, 2017",9.24,9.94,8.92,9.27,"8,178,690",- 129 | "Jul 03, 2017",9.33,10.08,8.56,9.19,"15,403,500",- 130 | "Jul 02, 2017",10.41,10.41,8.18,9.45,"23,967,300",- 131 | "Jul 01, 2017",11.96,12.12,10.37,10.39,"10,832,000",- 132 | "Jun 30, 2017",12.46,12.57,11.66,12.03,"14,022,600",- 133 | "Jun 29, 2017",14.09,14.09,12.33,12.48,"18,516,000",- 134 | "Jun 28, 2017",14.68,15.68,12.97,13.83,"40,650,500",- 135 | "Jun 27, 2017",12.27,15.19,11.94,14.47,"42,563,100",- 136 | "Jun 26, 2017",14.96,14.96,10.64,12.61,"25,803,900",- 137 | "Jun 25, 2017",16.34,16.70,14.36,14.92,"22,702,400",- 138 | "Jun 24, 2017",16.80,18.85,16.02,16.35,"34,660,100",- 139 | "Jun 23, 2017",12.13,18.58,11.97,16.99,"66,737,400",- 140 | "Jun 22, 2017",11.92,12.45,11.74,12.10,"16,740,600",- 141 | "Jun 21, 2017",11.40,12.55,11.38,11.83,"10,464,200",- 142 | "Jun 20, 2017",10.57,12.88,10.44,11.49,"22,123,200",- 143 | "Jun 19, 2017",10.49,11.30,10.26,10.59,"12,893,100",- 144 | "Jun 18, 2017",11.25,11.29,10.40,10.58,"5,475,110",- 145 | "Jun 17, 2017",11.24,11.45,11.02,11.25,"6,961,310",- 146 | "Jun 16, 2017",11.11,11.73,10.69,11.29,"7,179,610",- 147 | "Jun 15, 2017",11.80,11.80,9.80,11.11,"13,740,900",- 148 | "Jun 14, 2017",12.40,13.01,11.29,11.77,"18,671,800",- 149 | "Jun 13, 2017",11.06,12.52,10.97,12.42,"16,198,200",- 150 | "Jun 12, 2017",11.77,11.82,10.87,10.96,"8,663,550",- 151 | "Jun 11, 2017",11.36,12.23,11.10,11.76,"11,384,700",- 152 | "Jun 10, 2017",11.75,12.10,11.12,11.33,"14,370,200",- 153 | "Jun 09, 2017",12.35,13.12,11.30,11.74,"14,694,100",- 154 | "Jun 08, 2017",10.92,12.54,10.26,12.35,"12,978,300",- 155 | "Jun 07, 2017",11.57,11.86,10.93,10.97,"6,104,140",- 156 | "Jun 06, 2017",10.98,12.02,10.17,11.50,"11,135,000",- 157 | "Jun 05, 2017",12.13,12.58,10.88,11.17,"10,290,000",- 158 | "Jun 04, 2017",12.73,12.78,11.34,12.15,"15,253,900",- 159 | "Jun 03, 2017",13.17,13.70,11.39,12.54,"39,565,100",- 160 | "Jun 02, 2017",7.86,13.60,7.86,13.46,"54,232,400",- 161 | "Jun 01, 2017",4.86,8.37,4.78,7.79,"28,193,200",- 162 | "May 31, 2017",4.61,4.88,4.50,4.86,"3,011,070",- 163 | "May 30, 2017",4.62,5.07,4.53,4.65,"2,836,480",- 164 | "May 29, 2017",4.64,4.88,4.36,4.60,"2,205,420",- 165 | "May 28, 2017",4.86,5.06,4.19,4.62,"4,353,380",- 166 | "May 27, 2017",4.05,4.53,3.19,4.53,"7,046,840",- 167 | "May 26, 2017",4.66,5.33,3.39,4.10,"5,116,020",- 168 | "May 25, 2017",6.19,6.29,4.57,4.66,"6,211,020",- 169 | "May 24, 2017",6.42,6.76,5.68,6.19,"11,221,600",- 170 | -------------------------------------------------------------------------------- /v1/env.py: -------------------------------------------------------------------------------- 1 | ## to do: add side coin information! 2 | 3 | import os 4 | import pandas as pd 5 | import numpy as np 6 | import matplotlib.pyplot as plt 7 | 8 | 9 | available_coins = ["bitcoin_cash", "bitcoin", "bitconnect", "dash_price", "ethereum_classic", "ethereum", "iota", "litecoin", "monero", "nem", "neo", "numeraire", "omisego", "qtum", "ripple", "stratis", "waves"] 10 | 11 | 12 | class Coin: 13 | def __init__(self, coin_name="ethereum", recent_k = 0): 14 | # if coin_name not in available_coins: 15 | # raise Exception("Bad coin name!") 16 | self.coin_name = coin_name 17 | self.series = pd.read_csv("%s/cryptocurrencypricehistory/%s_price.csv" % (os.path.dirname(os.path.abspath(__file__)), self.coin_name), parse_dates=["Date"]) 18 | ## reorder so that date increases 19 | self.series.index = self.series.sort_values(by=["Date"]).index 20 | self.series = self.series.sort_index() 21 | 22 | if recent_k > 0: 23 | self.series = self.series[-recent_k:] 24 | self.series.index = [i for i in range(len(self.series))] 25 | 26 | self.length = len(self.series.index) 27 | self.current_index = 0 28 | 29 | #compute rolling mean and bollinger bands 30 | self.rm = self.series["Open"].rolling(window=20,center=False).mean() 31 | self.rstd = self.series["Open"].rolling(window=20,center=False).std() 32 | self.upper_band, self.lower_band = self.rm + 2 * self.rstd, self.rm - 2 * self.rstd 33 | 34 | 35 | def plot(self): 36 | ax = self.series["Open"].plot() 37 | ax.set_xlabel("Time") 38 | ax.set_ylabel("Price") 39 | plt.show() 40 | 41 | 42 | def advance(self): 43 | if self.current_index+1 < self.length: 44 | self.current_index += 1 45 | data = self.series.loc[self.current_index] 46 | return data 47 | else: 48 | return None 49 | 50 | def advance_n_step(self, step): 51 | if self.current_index+step < self.length: 52 | self.current_index += step 53 | data = self.series.loc[self.current_index] 54 | return data 55 | else: 56 | return None 57 | 58 | def getCurrentValue(self): 59 | return self.series.loc[self.current_index]["Open"] 60 | 61 | 62 | def getNextValue(self): 63 | if self.current_index + 1 >= self.length: 64 | return None 65 | return self.series.loc[self.current_index + 1]["Open"] 66 | 67 | def checkBollingerBands(self): 68 | isCrossUpperBand = 0 69 | if self.checkCrossUpperBand(): 70 | isCrossUpperBand = 1 71 | 72 | isCrossLowerBand = 0 73 | if self.checkCrossLowerBand(): 74 | isCrossLowerBand = 1 75 | 76 | return [isCrossUpperBand, isCrossLowerBand] 77 | 78 | 79 | def checkCrossUpperBand(self): 80 | return ( 81 | self.current_index - 1 >= 0 82 | and self.upper_band.loc[self.current_index - 1] <= self.getCurrentValue() 83 | and self.upper_band.loc[self.current_index] > self.getCurrentValue() 84 | ) 85 | 86 | def checkCrossLowerBand(self): 87 | return ( 88 | self.current_index - 1 >= 0 89 | and self.lower_band.loc[self.current_index - 1] >= self.getCurrentValue() 90 | and self.lower_band.loc[self.current_index] < self.getCurrentValue() 91 | ) 92 | 93 | 94 | def reset(self): 95 | self.current_index = 0 96 | 97 | -------------------------------------------------------------------------------- /v1/portfolio.py: -------------------------------------------------------------------------------- 1 | 2 | #Portfolio Class 3 | 4 | import numpy as np 5 | 6 | 7 | class Portfolio: 8 | 9 | def __init__(self, portfolio_cash=1000.0, coin=None): 10 | self.starting_cash = portfolio_cash 11 | # note this is a coin obj 12 | self.coin = coin 13 | self.portfolio_coin = 0 14 | self.portfolio_cash = portfolio_cash 15 | self.latest_coin_value = self.coin.getCurrentValue() 16 | 17 | # storage of historical data 18 | self.daily_returns = np.array([0.0]) 19 | self.daily_price = np.array([0.0]) 20 | 21 | def getCurrentValue(self): 22 | return self.portfolio_coin * self.coin.getCurrentValue() + self.portfolio_cash 23 | 24 | def getReturnsPercent(self): 25 | return 100 * (self.getCurrentValue() - self.starting_cash) / self.starting_cash 26 | 27 | def getCurrentHoldings(self): 28 | return "%.2f coins, %.2f cash, %.2f current value, %.2f percent returns" \ 29 | % (self.portfolio_coin, self.portfolio_cash, self.getCurrentValue(), self.getReturnsPercent()) 30 | 31 | def buy(self, coins_to_buy=0): 32 | current_price = self.coin.getCurrentValue() 33 | if not current_price: 34 | return 0 35 | amount_to_buy = min(self.portfolio_cash / current_price, coins_to_buy) 36 | self.portfolio_coin += amount_to_buy 37 | self.portfolio_cash -= amount_to_buy * current_price 38 | return amount_to_buy 39 | 40 | def sell(self, coins_to_sell=0): 41 | current_price = self.coin.getCurrentValue() 42 | if not current_price: 43 | return 0 44 | coin_to_sell = min(coins_to_sell, self.portfolio_coin) 45 | self.portfolio_coin -= coin_to_sell 46 | self.portfolio_cash += coin_to_sell * current_price 47 | return coin_to_sell 48 | 49 | def step(self): 50 | current_value = self.getCurrentValue() 51 | 52 | if self.coin.advance() is None: 53 | return False 54 | 55 | new_value = self.getCurrentValue() 56 | 57 | ## computing new features 58 | daily_return = (new_value - current_value) / current_value 59 | self.daily_returns = np.append(self.daily_returns, [daily_return]) 60 | 61 | 62 | return True 63 | 64 | def getCurrentState(self, features=["rolling_mean", "rolling_std", "sharpe_ratio", "bollinger_upper", "bollinger_lower"]): 65 | # state is represented by a feature vector 66 | # [avg_daily_return, sd_daily_return, sharpe_ratio, check_upper_band, check_lower_band] 67 | 68 | feature_dict = {} 69 | feature_dict["rolling_mean"] = self.daily_returns.mean() 70 | feature_dict["rolling_std"] = self.daily_returns.std() 71 | 72 | if feature_dict["rolling_std"] == 0: 73 | sharpe_ratio = 0 74 | else: 75 | sharpe_ratio = np.sqrt(252) * (feature_dict["rolling_mean"] / feature_dict["rolling_std"]) 76 | feature_dict["sharpe_ratio"] = sharpe_ratio 77 | 78 | # check if the price is outside the Bollinger Bands 79 | check_upper_band, check_lower_band = self.coin.checkBollingerBands() 80 | feature_dict["bollinger_upper"] = check_upper_band 81 | feature_dict["bollinger_lower"] = check_lower_band 82 | return [feature_dict[feature] for feature in features] 83 | 84 | def reset(self): 85 | self.coin.reset() 86 | self.portfolio_coin = 0 87 | self.portfolio_cash = self.starting_cash 88 | self.latest_coin_value = self.coin.getCurrentValue() 89 | self.daily_returns = np.array([0.0]) 90 | -------------------------------------------------------------------------------- /v1/simulator.py: -------------------------------------------------------------------------------- 1 | 2 | # Cryptocurrency Market Simulator 3 | 4 | from env import Coin 5 | from portfolio import Portfolio 6 | from random import randint 7 | from enum import Enum 8 | 9 | class Action(Enum): 10 | HOLD=0 11 | BUY=1 12 | SELL=2 13 | 14 | 15 | class Simulator: 16 | def __init__(self, num_coins_per_order=1, 17 | portfolio_cash=1000.0, 18 | coin=Coin("ethereum"), 19 | features=["rolling_mean", "rolling_std", "sharpe_ratio", "bollinger_upper", "bollinger_lower"]): 20 | self.num_coins_per_order = num_coins_per_order 21 | self.coin = coin 22 | self.portfolio = Portfolio(portfolio_cash=portfolio_cash, coin=coin) 23 | self.features = features 24 | 25 | def get_current_state(self): 26 | return self.portfolio.getCurrentState(self.features) 27 | 28 | 29 | def get_current_holdings(self): 30 | return self.portfolio.getCurrentHoldings() 31 | 32 | 33 | def get_ran_action(self): 34 | return Action(randint(0,2)) 35 | 36 | 37 | def act_and_step(self, action): 38 | #print 'Taking action:', action 39 | if action == Action.BUY: 40 | self.portfolio.buy(self.num_coins_per_order) 41 | elif action == Action.SELL: 42 | self.portfolio.sell(self.num_coins_per_order) 43 | 44 | state = self.get_current_state() 45 | reward = self.portfolio.getReturnsPercent() 46 | 47 | if self.portfolio.step() is False: 48 | return [state, reward, True] 49 | 50 | return [state, reward, False] 51 | 52 | 53 | def reset(self): 54 | self.portfolio.reset() 55 | 56 | 57 | def get_state_size(self): 58 | return len(self.get_current_state()) 59 | 60 | def get_action_size(self): 61 | return len(Action) 62 | 63 | 64 | def plot_coin_price(self): 65 | self.coin.plot() -------------------------------------------------------------------------------- /v1/trader.py: -------------------------------------------------------------------------------- 1 | from simulator import * 2 | from env import * 3 | from portfolio import * 4 | 5 | 6 | # Q Value Function Approximator 7 | # Neural Network Implementation 8 | 9 | from keras.models import Sequential 10 | from keras.layers import Dense 11 | from keras.optimizers import Adam 12 | from keras import backend as K 13 | from keras.models import load_model 14 | 15 | class QValue_NN: 16 | 17 | # init neural network 18 | def __init__(self, state_size, action_size, units): 19 | # define input and target shapes 20 | self._state_size = state_size 21 | self._action_size = action_size 22 | 23 | self._units = units 24 | 25 | # init model 26 | self._model = self._build_model() 27 | 28 | 29 | # define loss function 30 | def _huber_loss(self, target, prediction): 31 | # sqrt(1+error^2)-1 32 | error = prediction - target 33 | return K.mean(K.sqrt(1+K.square(error))-1, axis=-1) 34 | 35 | 36 | # neural net for Deep-Q Learning Model 37 | def _build_model(self): 38 | model = Sequential() 39 | model.add(Dense(self._units, input_dim=self._state_size, activation='relu')) 40 | model.add(Dense(self._units, activation='relu')) 41 | model.add(Dense(self._action_size, activation='linear')) 42 | model.compile(loss=self._huber_loss, optimizer='adam') 43 | return model 44 | 45 | 46 | # online training 47 | def train(self, state, qvalues): 48 | state_reshape = np.reshape(state, [1, len(state)]) 49 | self._model.fit(state_reshape, qvalues, epochs=1, verbose=0) 50 | 51 | 52 | # get q-values based on state 53 | def predict(self, state): 54 | state_reshape = np.reshape(state, [1, len(state)]) 55 | return self._model.predict(state_reshape) 56 | 57 | def set_weights(self, model_weights): 58 | self._model.set_weights(model_weights) 59 | 60 | def get_weights(self): 61 | return self._model.get_weights() 62 | 63 | def save(self, path): 64 | self._model.save_weights(path) 65 | 66 | def load(self, path): 67 | self._model.load_weights(path) 68 | 69 | 70 | # Cryptocurrency Trader Q-Learning Implementation 71 | 72 | import random 73 | import numpy as np 74 | from collections import deque 75 | 76 | class Crypto_Trader: 77 | 78 | def __init__(self, gamma = 0.95, epsilon = 1.0, epsilon_min = 0.01, 79 | epsilon_decay = 0.99, num_episodes = 1000, 80 | num_neutron = 24, num_coins_per_order = 100, init_capital = 1000, 81 | coin_name = 'ethereum', recent_k = 0, 82 | features=["rolling_mean", "rolling_std", "sharpe_ratio", "bollinger_upper", "bollinger_lower"]): 83 | 84 | self.memory = deque(maxlen=2000) 85 | self.batch_size = 300 86 | 87 | # Reward Discount Rate 88 | self.gamma = gamma 89 | 90 | # Esiplon (exploration factor) 91 | self.epsilon = epsilon 92 | 93 | self.epsilon_min = epsilon_min 94 | 95 | # Reduce exploration overtime 96 | self.epsilon_decay = epsilon_decay 97 | 98 | # number of episodes for training 99 | self.num_episodes = num_episodes 100 | 101 | self.features = features 102 | 103 | # init simulator 104 | self.coin_name = coin_name 105 | self.simulator = Simulator(num_coins_per_order, init_capital, Coin(coin_name, recent_k), features=self.features) 106 | 107 | # init NN model 108 | self.model = QValue_NN(self.simulator.get_state_size(), self.simulator.get_action_size(), num_neutron) 109 | self.target_model = QValue_NN(self.simulator.get_state_size(), self.simulator.get_action_size(), num_neutron) 110 | 111 | 112 | def plot_coin_price(self): 113 | self.simulator.plot_coin_price() 114 | 115 | 116 | def act(self, state, epsilon): 117 | # Choose action by e-greedy 118 | if np.random.rand() < epsilon: 119 | #print 'random' 120 | return self.simulator.get_ran_action() 121 | 122 | # Get Q values, choose action by Q values 123 | act_values = self.model.predict(state) 124 | return Action(np.argmax(act_values[0])) 125 | 126 | 127 | def remember(self, state, action, reward, next_state, isDone): 128 | self.memory.append((state, action, reward, next_state, isDone)) 129 | 130 | 131 | def update_target_model(self): 132 | # copy weights from model to target_model 133 | self.target_model.set_weights(self.model.get_weights()) 134 | 135 | 136 | def replay(self): 137 | minibatch = random.sample(self.memory, self.batch_size) 138 | 139 | for state, action, reward, next_state, isDone in minibatch: 140 | target = self.model.predict(state) 141 | if isDone: 142 | target[0][action.value] = reward 143 | else: 144 | a = self.model.predict(next_state)[0] 145 | t = self.target_model.predict(next_state)[0] 146 | target[0][action.value] = reward + self.gamma * t[np.argmax(a)] 147 | self.model.train(state, target) 148 | 149 | if self.epsilon > self.epsilon_min: 150 | self.epsilon *= self.epsilon_decay 151 | 152 | 153 | def train(self): 154 | for i in range(self.num_episodes): 155 | 156 | self.simulator.reset() 157 | state = self.simulator.get_current_state() 158 | 159 | while (True): 160 | 161 | action = self.act(state, self.epsilon) 162 | #print action 163 | 164 | # step to the next state and reward based on action 165 | next_state, reward, isDone = self.simulator.act_and_step(action) 166 | #print next_state 167 | #print reward 168 | 169 | self.remember(state, action, reward, next_state, isDone) 170 | state = next_state 171 | 172 | if isDone: 173 | self.update_target_model() 174 | print("episode: {}/{}, reward: {}, epsilon: {:.2}" 175 | .format(i+1, self.num_episodes, reward, self.epsilon)) 176 | #print self.simulator.get_current_holdings() 177 | break 178 | 179 | if len(self.memory) > self.batch_size: 180 | self.replay() 181 | 182 | self.target_model.save('model/{}.model.v2.h5'.format(self.coin_name)) 183 | 184 | 185 | def test(self, epsilon = None): 186 | if epsilon is None: 187 | epsilon = self.epsilon 188 | 189 | self.simulator.reset() 190 | # self.model.load('model/{}.model.v2.h5'.format(self.coin_name)) 191 | state = self.simulator.get_current_state() 192 | while (True): 193 | 194 | action = self.act(state, epsilon) 195 | 196 | # step to the next state and reward based on action 197 | next_state, reward, isDone = self.simulator.act_and_step(action) 198 | print state, action, reward, next_state, isDone 199 | 200 | self.remember(state, action, reward, next_state, isDone) 201 | state = next_state 202 | 203 | if isDone: 204 | print("Test run: reward: {}, holdings: {}" 205 | .format(reward, self.simulator.get_current_holdings())) 206 | break 207 | -------------------------------------------------------------------------------- /v2/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GradientTrader/simulator/d82e36860072df09f7c67f6771504a3a5aa66b8f/v2/__init__.py -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/bitcoin_cash_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",602.68,626.21,602.45,616.30,"375,367,000","10,105,200,000" 3 | "Nov 06, 2017",630.31,657.34,602.65,602.65,"794,105,000","10,566,600,000" 4 | "Nov 05, 2017",619.91,635.72,579.13,630.70,"816,028,000","10,390,900,000" 5 | "Nov 04, 2017",635.35,642.05,571.12,620.45,"1,161,370,000","10,647,200,000" 6 | "Nov 03, 2017",587.32,684.53,577.86,625.32,"1,682,210,000","9,839,760,000" 7 | "Nov 02, 2017",527.68,610.39,514.52,587.22,"1,632,060,000","8,840,010,000" 8 | "Nov 01, 2017",438.30,538.26,437.91,531.83,"1,152,230,000","7,342,250,000" 9 | "Oct 31, 2017",449.37,454.07,431.76,439.05,"343,799,000","7,527,260,000" 10 | "Oct 30, 2017",458.45,478.42,417.62,448.23,"796,409,000","7,679,000,000" 11 | "Oct 29, 2017",420.47,526.12,408.40,451.92,"2,002,440,000","7,042,260,000" 12 | "Oct 28, 2017",369.54,425.44,369.06,423.35,"781,037,000","6,183,520,000" 13 | "Oct 27, 2017",338.30,372.81,338.24,367.57,"501,989,000","5,655,870,000" 14 | "Oct 26, 2017",332.11,350.94,331.21,338.20,"234,967,000","5,550,700,000" 15 | "Oct 25, 2017",326.59,334.38,320.38,332.13,"151,935,000","5,457,720,000" 16 | "Oct 24, 2017",315.90,340.45,311.48,326.89,"267,442,000","5,278,410,000" 17 | "Oct 23, 2017",330.67,332.28,309.87,315.60,"191,558,000","5,524,790,000" 18 | "Oct 22, 2017",323.50,355.52,323.50,331.66,"355,546,000","5,405,020,000" 19 | "Oct 21, 2017",326.75,328.45,317.46,323.36,"129,938,000","5,458,980,000" 20 | "Oct 20, 2017",330.90,332.98,323.08,327.44,"160,204,000","5,527,860,000" 21 | "Oct 19, 2017",339.27,339.27,326.27,330.81,"195,578,000","5,667,070,000" 22 | "Oct 18, 2017",373.65,376.18,313.77,339.17,"477,184,000","6,240,990,000" 23 | "Oct 17, 2017",313.70,394.96,309.64,371.73,"1,008,160,000","5,239,520,000" 24 | "Oct 16, 2017",315.26,318.02,310.52,313.64,"117,797,000","5,265,400,000" 25 | "Oct 15, 2017",322.42,323.59,307.68,314.95,"133,385,000","5,384,760,000" 26 | "Oct 14, 2017",321.54,327.42,317.35,321.96,"164,137,000","5,369,720,000" 27 | "Oct 13, 2017",314.15,323.08,304.38,321.46,"288,210,000","5,242,630,000" 28 | "Oct 12, 2017",315.47,330.13,310.71,313.21,"262,066,000","5,262,390,000" 29 | "Oct 11, 2017",320.20,321.26,312.13,314.90,"131,577,000","5,341,000,000" 30 | "Oct 10, 2017",313.22,352.02,311.70,321.59,"367,809,000","5,224,170,000" 31 | "Oct 09, 2017",342.76,342.76,289.04,314.16,"288,075,000","5,716,320,000" 32 | "Oct 08, 2017",360.09,362.46,337.00,342.21,"203,754,000","6,004,940,000" 33 | "Oct 07, 2017",363.60,364.88,356.06,360.78,"91,004,000","6,062,860,000" 34 | "Oct 06, 2017",355.44,371.28,354.96,363.01,"182,031,000","5,926,540,000" 35 | "Oct 05, 2017",358.42,371.19,348.45,355.75,"268,341,000","5,971,260,000" 36 | "Oct 04, 2017",404.20,404.45,354.55,358.45,"251,584,000","6,729,640,000" 37 | "Oct 03, 2017",421.79,421.79,395.74,404.18,"130,247,000","7,022,370,000" 38 | "Oct 02, 2017",415.87,430.86,411.84,421.19,"219,590,000","6,921,580,000" 39 | "Oct 01, 2017",433.38,436.94,415.15,415.15,"164,290,000","7,207,770,000" 40 | "Sep 30, 2017",436.64,445.62,432.53,432.63,"150,565,000","7,258,880,000" 41 | "Sep 29, 2017",447.66,447.92,426.99,436.77,"148,725,000","7,441,960,000" 42 | "Sep 28, 2017",456.71,465.20,433.50,447.81,"300,421,000","7,592,000,000" 43 | "Sep 27, 2017",441.86,460.00,439.41,457.31,"197,885,000","7,343,490,000" 44 | "Sep 26, 2017",445.36,458.25,441.83,441.83,"165,303,000","7,400,020,000" 45 | "Sep 25, 2017",419.65,450.13,419.65,445.80,"302,272,000","6,971,280,000" 46 | "Sep 24, 2017",428.80,433.04,419.25,421.03,"114,527,000","7,121,950,000" 47 | "Sep 23, 2017",415.31,432.96,407.45,428.50,"189,127,000","6,895,970,000" 48 | "Sep 22, 2017",417.92,435.44,402.77,415.09,"241,905,000","6,937,170,000" 49 | "Sep 21, 2017",475.83,480.00,413.75,416.26,"316,731,000","7,898,300,000" 50 | "Sep 20, 2017",526.74,527.72,471.09,476.05,"669,264,000","8,741,670,000" 51 | "Sep 19, 2017",480.64,550.41,450.05,527.88,"802,321,000","7,975,010,000" 52 | "Sep 18, 2017",422.09,479.69,422.09,479.32,"458,550,000","7,001,640,000" 53 | "Sep 17, 2017",438.90,438.90,384.06,419.86,"221,828,000","7,279,520,000" 54 | "Sep 16, 2017",424.49,450.98,388.20,440.22,"313,583,000","7,039,590,000" 55 | "Sep 15, 2017",369.49,448.39,301.69,424.02,"707,231,000","6,126,800,000" 56 | "Sep 14, 2017",504.22,510.47,367.04,367.04,"257,431,000","8,359,650,000" 57 | "Sep 13, 2017",509.47,519.20,471.22,503.61,"340,344,000","8,445,540,000" 58 | "Sep 12, 2017",539.03,559.22,505.01,510.41,"273,825,000","8,934,220,000" 59 | "Sep 11, 2017",537.19,556.25,515.67,537.81,"274,712,000","8,902,570,000" 60 | "Sep 10, 2017",546.48,546.75,484.09,537.07,"289,508,000","9,055,430,000" 61 | "Sep 09, 2017",584.73,586.18,539.15,547.47,"234,578,000","9,688,150,000" 62 | "Sep 08, 2017",654.37,687.30,557.50,583.10,"809,763,000","10,840,500,000" 63 | "Sep 07, 2017",636.85,707.98,603.50,652.86,"1,082,380,000","10,548,500,000" 64 | "Sep 06, 2017",541.28,642.69,539.96,638.18,"693,240,000","8,964,700,000" 65 | "Sep 05, 2017",514.90,550.95,458.78,541.71,"338,978,000","8,527,100,000" 66 | "Sep 04, 2017",608.26,608.26,500.75,517.24,"328,957,000","10,072,200,000" 67 | "Sep 03, 2017",578.27,617.41,563.59,607.43,"344,862,000","9,574,520,000" 68 | "Sep 02, 2017",621.96,642.05,560.58,575.90,"350,478,000","10,297,000,000" 69 | "Sep 01, 2017",588.40,645.52,586.73,622.17,"393,839,000","9,740,460,000" 70 | "Aug 31, 2017",576.25,603.69,572.14,588.17,"298,144,000","9,538,750,000" 71 | "Aug 30, 2017",549.32,604.69,535.92,575.21,"443,856,000","9,092,300,000" 72 | "Aug 29, 2017",596.13,599.30,528.32,552.93,"370,017,000","9,866,110,000" 73 | "Aug 28, 2017",619.70,626.88,595.52,596.18,"216,273,000","10,254,800,000" 74 | "Aug 27, 2017",625.89,654.87,589.63,620.90,"402,718,000","10,357,000,000" 75 | "Aug 26, 2017",641.88,646.93,622.36,625.32,"193,414,000","10,616,100,000" 76 | "Aug 25, 2017",627.06,665.41,624.30,641.05,"348,632,000","10,365,600,000" 77 | "Aug 24, 2017",670.03,697.32,617.31,628.11,"407,177,000","11,071,100,000" 78 | "Aug 23, 2017",690.96,715.67,651.32,669.40,"501,983,000","11,416,800,000" 79 | "Aug 22, 2017",596.19,734.88,570.27,690.88,"1,393,260,000","9,844,620,000" 80 | "Aug 21, 2017",723.70,756.59,573.47,599.63,"1,123,400,000","11,943,100,000" 81 | "Aug 20, 2017",772.42,858.96,683.94,712.87,"1,494,020,000","12,742,600,000" 82 | "Aug 19, 2017",697.04,1091.97,625.16,754.56,"3,196,230,000","11,498,100,000" 83 | "Aug 18, 2017",458.67,764.07,458.67,690.24,"3,087,490,000","7,565,590,000" 84 | "Aug 17, 2017",301.02,460.53,293.10,460.53,"744,605,000","4,964,980,000" 85 | "Aug 16, 2017",297.97,307.62,290.21,300.21,"106,436,000","4,914,350,000" 86 | "Aug 15, 2017",298.19,306.52,292.88,297.86,"133,924,000","4,917,480,000" 87 | "Aug 14, 2017",296.10,327.39,293.50,297.68,"174,968,000","4,882,720,000" 88 | "Aug 13, 2017",316.29,317.47,298.05,298.05,"120,722,000","5,215,330,000" 89 | "Aug 12, 2017",327.82,341.85,313.70,317.09,"126,007,000","5,405,200,000" 90 | "Aug 11, 2017",275.88,351.16,275.02,328.24,"233,971,000","4,548,600,000" 91 | "Aug 10, 2017",305.21,311.68,274.68,275.95,"136,637,000","5,031,790,000" 92 | "Aug 09, 2017",345.28,349.32,298.61,303.89,"165,032,000","5,691,960,000" 93 | "Aug 08, 2017",321.35,386.29,309.61,345.49,"274,880,000","5,297,390,000" 94 | "Aug 07, 2017",223.76,373.87,223.76,319.69,"346,546,000","3,688,360,000" 95 | "Aug 06, 2017",212.18,223.70,203.44,220.66,"107,606,000","3,497,290,000" 96 | "Aug 05, 2017",231.11,273.04,200.98,213.15,"144,043,000","3,809,330,000" 97 | "Aug 04, 2017",362.18,386.93,233.05,233.05,"185,038,000","5,969,720,000" 98 | "Aug 03, 2017",448.49,519.28,364.05,364.05,"161,518,000","7,392,030,000" 99 | "Aug 02, 2017",382.38,756.93,309.33,452.66,"416,207,000","6,302,360,000" 100 | "Aug 01, 2017",294.60,426.11,210.38,380.01,"65,988,800",- 101 | "Jul 31, 2017",346.36,347.82,266.19,294.46,"1,075,960",- 102 | "Jul 30, 2017",385.14,385.14,316.25,345.66,"606,695",- 103 | "Jul 29, 2017",410.56,423.73,323.73,384.77,"737,815",- 104 | "Jul 28, 2017",386.65,465.18,217.06,406.05,"1,230,160",- 105 | "Jul 27, 2017",417.10,460.97,367.78,385.48,"533,207",- 106 | "Jul 26, 2017",407.08,486.16,321.79,365.82,"1,784,640",- 107 | "Jul 25, 2017",441.35,541.66,338.09,406.90,"524,908",- 108 | "Jul 24, 2017",412.58,578.89,409.21,440.70,"190,952",- 109 | "Jul 23, 2017",555.89,578.97,411.78,413.06,"85,013",- 110 | -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/bitconnect_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",260.04,273.18,260.04,271.27,"22,712,300","555,997,000" 3 | "Nov 06, 2017",276.58,279.72,259.64,259.85,"19,432,300","591,355,000" 4 | "Nov 05, 2017",278.10,285.64,273.37,276.28,"14,591,800","594,608,000" 5 | "Nov 04, 2017",270.45,284.62,259.07,278.66,"66,891,000","578,248,000" 6 | "Nov 03, 2017",262.93,284.64,260.10,271.12,"25,755,600","1,934,570,000" 7 | "Nov 02, 2017",251.29,273.73,251.29,263.27,"23,900,000","1,846,340,000" 8 | "Nov 01, 2017",239.45,251.29,234.88,250.93,"24,030,900","1,757,760,000" 9 | "Oct 31, 2017",227.38,239.52,226.79,239.52,"18,364,400","1,667,460,000" 10 | "Oct 30, 2017",225.77,230.18,223.09,228.12,"22,568,300","1,653,970,000" 11 | "Oct 29, 2017",211.72,233.22,211.18,227.10,"11,138,200","1,549,720,000" 12 | "Oct 28, 2017",213.13,217.36,209.66,211.84,"10,550,800","1,558,580,000" 13 | "Oct 27, 2017",216.65,220.70,210.38,212.55,"14,048,500","1,582,930,000" 14 | "Oct 26, 2017",206.38,220.18,205.15,216.59,"15,882,500","1,506,580,000" 15 | "Oct 25, 2017",193.74,206.68,188.80,206.32,"17,013,600","1,405,090,000" 16 | "Oct 24, 2017",196.65,201.47,186.31,193.70,"12,298,000","1,424,770,000" 17 | "Oct 23, 2017",204.72,208.28,193.84,198.57,"13,730,900","1,481,770,000" 18 | "Oct 22, 2017",208.50,210.75,198.85,205.04,"9,944,220","1,507,780,000" 19 | "Oct 21, 2017",213.01,218.42,204.56,210.40,"10,211,700","1,538,750,000" 20 | "Oct 20, 2017",199.81,216.68,198.23,213.46,"15,662,400","1,442,010,000" 21 | "Oct 19, 2017",195.58,202.03,194.07,199.79,"14,086,400","1,410,190,000" 22 | "Oct 18, 2017",193.93,196.44,178.70,195.38,"13,234,800","1,395,380,000" 23 | "Oct 17, 2017",199.63,200.25,191.38,193.95,"14,142,600","1,434,990,000" 24 | "Oct 16, 2017",193.05,200.68,190.66,199.63,"14,092,700","1,385,880,000" 25 | "Oct 15, 2017",200.83,201.44,186.43,193.03,"9,190,960","1,440,370,000" 26 | "Oct 14, 2017",196.68,201.51,193.34,199.74,"12,375,600","1,409,300,000" 27 | "Oct 13, 2017",188.67,204.19,187.51,196.72,"18,181,900","1,350,390,000" 28 | "Oct 12, 2017",166.71,188.09,166.23,188.09,"15,616,200","1,182,750,000" 29 | "Oct 11, 2017",161.34,168.28,158.95,166.59,"13,011,800","1,143,640,000" 30 | "Oct 10, 2017",158.71,166.74,158.71,161.25,"13,035,600","1,116,440,000" 31 | "Oct 09, 2017",148.29,161.37,146.63,158.66,"12,646,700","1,034,940,000" 32 | "Oct 08, 2017",142.71,148.93,142.33,148.31,"6,956,630","995,090,000" 33 | "Oct 07, 2017",141.85,144.33,139.16,144.15,"6,342,670","984,296,000" 34 | "Oct 06, 2017",138.96,143.83,138.68,141.86,"10,787,200","958,272,000" 35 | "Oct 05, 2017",135.21,140.32,132.93,138.96,"8,245,120","931,554,000" 36 | "Oct 04, 2017",136.92,138.58,134.12,135.09,"7,468,280","941,932,000" 37 | "Oct 03, 2017",139.07,139.75,134.20,136.58,"8,298,420","955,766,000" 38 | "Oct 02, 2017",139.19,140.60,134.72,139.08,"11,113,800","953,552,000" 39 | "Oct 01, 2017",136.23,139.33,134.03,139.33,"5,808,050","932,178,000" 40 | "Sep 30, 2017",130.13,136.54,128.68,136.16,"7,830,160","889,567,000" 41 | "Sep 29, 2017",131.15,132.31,123.58,130.11,"10,871,800","895,647,000" 42 | "Sep 28, 2017",126.30,131.58,125.18,131.26,"12,807,500","861,593,000" 43 | "Sep 27, 2017",117.41,127.13,117.36,126.31,"10,526,200","800,032,000" 44 | "Sep 26, 2017",117.50,120.41,116.41,117.76,"10,629,600","796,741,000" 45 | "Sep 25, 2017",109.68,119.57,109.51,117.50,"10,414,100","742,949,000" 46 | "Sep 24, 2017",113.12,113.27,108.57,110.11,"4,950,760","765,508,000" 47 | "Sep 23, 2017",109.38,113.91,108.24,113.17,"5,640,310","739,413,000" 48 | "Sep 22, 2017",108.61,113.21,107.07,109.69,"6,933,750","733,372,000" 49 | "Sep 21, 2017",116.67,117.45,107.42,108.73,"6,427,510","787,024,000" 50 | "Sep 20, 2017",117.55,121.48,114.45,117.25,"8,498,270","792,175,000" 51 | "Sep 19, 2017",122.20,123.11,114.60,117.67,"9,224,430","822,711,000" 52 | "Sep 18, 2017",106.62,122.23,106.49,122.00,"8,192,160","716,916,000" 53 | "Sep 17, 2017",109.75,110.94,102.81,106.84,"5,350,380","737,226,000" 54 | "Sep 16, 2017",111.11,116.01,105.02,109.85,"5,683,580","744,652,000" 55 | "Sep 15, 2017",97.42,113.75,89.36,111.22,"8,539,660","652,107,000" 56 | "Sep 14, 2017",115.97,117.38,96.71,96.71,"6,367,800","775,543,000" 57 | "Sep 13, 2017",123.14,123.70,112.60,115.97,"6,315,510","822,282,000" 58 | "Sep 12, 2017",125.29,130.91,122.22,123.50,"6,861,080","835,911,000" 59 | "Sep 11, 2017",121.88,128.20,120.76,125.70,"7,083,720","812,292,000" 60 | "Sep 10, 2017",129.70,129.70,118.94,122.92,"4,644,030","863,579,000" 61 | "Sep 09, 2017",128.51,131.51,125.21,130.05,"6,225,680","854,520,000" 62 | "Sep 08, 2017",137.68,139.78,123.23,128.29,"7,051,050","914,556,000" 63 | "Sep 07, 2017",135.88,138.67,132.52,137.61,"7,564,730","901,778,000" 64 | "Sep 06, 2017",130.25,142.16,128.84,136.18,"8,049,390","863,537,000" 65 | "Sep 05, 2017",114.74,131.57,108.93,129.42,"8,537,600","756,793,000" 66 | "Sep 04, 2017",128.26,129.55,110.68,114.13,"30,395,600","845,031,000" 67 | "Sep 03, 2017",131.71,135.06,125.87,130.99,"5,244,490","866,869,000" 68 | "Sep 02, 2017",141.11,142.80,128.00,131.33,"5,056,030","926,918,000" 69 | "Sep 01, 2017",135.66,140.97,133.47,140.97,"7,854,700","890,229,000" 70 | "Aug 31, 2017",135.60,136.88,132.24,135.63,"6,633,480","888,920,000" 71 | "Aug 30, 2017",128.06,137.29,127.68,136.06,"9,923,160","838,560,000" 72 | "Aug 29, 2017",119.01,129.24,114.84,128.24,"9,907,640","778,470,000" 73 | "Aug 28, 2017",114.84,120.45,86.11,118.75,"6,444,290","750,345,000" 74 | "Aug 27, 2017",116.11,129.98,101.65,114.99,"4,895,670","757,691,000" 75 | "Aug 26, 2017",100.14,136.51,93.25,116.13,"995,116","652,789,000" 76 | "Aug 25, 2017",123.40,149.89,38.98,100.87,"3,353,200","803,652,000" 77 | "Aug 24, 2017",128.05,131.49,119.89,127.08,"8,552,010","832,860,000" 78 | "Aug 23, 2017",120.20,130.43,119.72,127.97,"9,692,110","781,010,000" 79 | "Aug 22, 2017",116.16,121.95,106.55,120.44,"6,273,350","754,043,000" 80 | "Aug 21, 2017",116.32,118.05,112.68,115.91,"7,667,050","754,278,000" 81 | "Aug 20, 2017",119.53,119.61,114.63,116.77,"4,730,720","774,327,000" 82 | "Aug 19, 2017",121.01,132.04,111.47,120.04,"6,751,140","783,024,000" 83 | "Aug 18, 2017",117.65,124.19,115.06,121.08,"7,858,910","760,435,000" 84 | "Aug 17, 2017",119.23,122.91,115.32,117.90,"9,416,780","769,810,000" 85 | "Aug 16, 2017",112.38,119.41,107.07,119.36,"8,065,040","724,865,000" 86 | "Aug 15, 2017",113.03,116.79,104.35,112.26,"8,375,150","728,298,000" 87 | "Aug 14, 2017",103.30,112.83,98.87,112.73,"7,806,160","664,460,000" 88 | "Aug 13, 2017",104.71,113.37,100.17,103.23,"5,104,100","672,851,000" 89 | "Aug 12, 2017",98.88,106.88,97.91,104.76,"6,396,390","634,327,000" 90 | "Aug 11, 2017",91.57,100.27,91.22,98.96,"8,535,500","586,851,000" 91 | "Aug 10, 2017",85.94,92.18,85.46,91.54,"8,170,850","550,213,000" 92 | "Aug 09, 2017",86.45,86.89,83.16,85.91,"6,557,630","552,995,000" 93 | "Aug 08, 2017",83.13,87.32,83.03,86.51,"8,050,680","530,677,000" 94 | "Aug 07, 2017",79.20,84.90,78.36,83.05,"4,506,370","505,097,000" 95 | "Aug 06, 2017",79.13,81.21,75.75,79.32,"3,382,890","504,140,000" 96 | "Aug 05, 2017",70.72,80.61,70.72,79.13,"4,215,220","450,089,000" 97 | "Aug 04, 2017",69.41,71.10,67.85,70.90,"4,766,590","441,261,000" 98 | "Aug 03, 2017",65.09,69.85,64.73,69.35,"4,382,480","413,366,000" 99 | "Aug 02, 2017",50.73,70.30,49.78,64.93,"3,277,460","321,857,000" 100 | "Aug 01, 2017",65.98,66.14,41.09,52.44,"261,126","416,441,000" 101 | "Jul 31, 2017",61.29,66.64,57.91,66.14,"1,578,510","386,447,000" 102 | "Jul 30, 2017",65.08,65.16,61.26,61.52,"2,147,470","409,831,000" 103 | "Jul 29, 2017",69.08,69.23,64.04,64.96,"2,912,860","434,587,000" 104 | "Jul 28, 2017",65.28,69.94,64.79,69.28,"4,174,750","410,202,000" 105 | "Jul 27, 2017",63.01,66.09,62.21,65.09,"3,508,340","395,556,000" 106 | "Jul 26, 2017",63.57,64.46,60.63,62.68,"3,436,370","398,636,000" 107 | "Jul 25, 2017",67.01,67.01,60.14,63.65,"3,566,120","413,094,000" 108 | "Jul 24, 2017",61.33,68.22,58.44,67.02,"3,991,940","374,541,000" 109 | "Jul 23, 2017",67.36,67.85,58.75,60.14,"2,132,900","410,971,000" 110 | "Jul 22, 2017",67.23,70.84,65.63,67.31,"3,077,890","409,779,000" 111 | "Jul 21, 2017",70.31,70.55,65.47,67.21,"4,225,470","423,696,000" 112 | "Jul 20, 2017",56.44,72.00,56.44,69.79,"4,378,970","334,334,000" 113 | "Jul 19, 2017",58.38,60.22,55.72,56.61,"3,140,970","345,452,000" 114 | "Jul 18, 2017",55.72,59.98,53.81,58.29,"3,540,910","329,330,000" 115 | "Jul 17, 2017",47.74,55.83,47.74,55.49,"3,778,790","281,529,000" 116 | "Jul 16, 2017",44.22,50.56,29.87,48.05,"2,100,690","260,770,000" 117 | "Jul 15, 2017",55.45,55.55,44.57,44.57,"2,687,210","383,760,000" 118 | "Jul 14, 2017",57.60,58.57,53.94,55.53,"3,445,520","398,102,000" 119 | "Jul 13, 2017",57.99,58.89,57.02,57.64,"3,024,130","400,400,000" 120 | "Jul 12, 2017",54.99,58.86,53.61,58.26,"2,740,060","379,392,000" 121 | "Jul 11, 2017",53.64,56.96,53.28,55.07,"2,767,260","368,502,000" 122 | "Jul 10, 2017",58.67,59.60,53.45,53.97,"2,949,720","402,702,000" 123 | "Jul 09, 2017",60.22,60.45,58.61,58.96,"1,992,460","412,952,000" 124 | "Jul 08, 2017",56.60,60.25,56.60,60.18,"2,447,650","387,783,000" 125 | "Jul 07, 2017",59.13,59.79,56.58,56.58,"4,205,810","404,767,000" 126 | "Jul 06, 2017",57.11,63.80,56.92,59.06,"3,277,810","390,587,000" 127 | "Jul 05, 2017",55.52,57.30,53.62,57.08,"2,954,260","379,307,000" 128 | "Jul 04, 2017",53.24,55.52,53.22,55.48,"2,748,610","363,460,000" 129 | "Jul 03, 2017",51.81,54.06,51.35,53.36,"3,417,230","353,379,000" 130 | "Jul 02, 2017",50.04,52.40,49.62,52.04,"1,326,100","341,010,000" 131 | "Jul 01, 2017",51.37,52.15,49.61,50.04,"2,650,800","349,775,000" 132 | "Jun 30, 2017",51.94,53.10,50.86,51.39,"2,126,610","353,252,000" 133 | "Jun 29, 2017",52.06,52.82,51.04,51.84,"2,865,970","353,750,000" 134 | "Jun 28, 2017",51.31,52.62,49.94,52.11,"2,985,300","348,397,000" 135 | "Jun 27, 2017",49.50,50.77,46.29,50.56,"2,410,340","335,744,000" 136 | "Jun 26, 2017",51.11,52.74,47.31,48.33,"2,220,370","346,232,000" 137 | "Jun 25, 2017",52.76,54.14,50.46,51.16,"2,464,490","357,030,000" 138 | "Jun 24, 2017",55.65,56.40,51.81,52.87,"2,270,790","376,295,000" 139 | "Jun 23, 2017",52.31,56.73,51.25,55.67,"2,353,480","353,360,000" 140 | "Jun 22, 2017",51.25,52.30,50.28,52.30,"2,264,670","345,886,000" 141 | "Jun 21, 2017",52.41,52.67,48.98,51.27,"1,981,900","353,405,000" 142 | "Jun 20, 2017",51.36,52.76,51.08,52.42,"1,991,020","346,100,000" 143 | "Jun 19, 2017",50.96,51.66,50.90,51.38,"1,827,540","343,207,000" 144 | "Jun 18, 2017",51.02,51.62,50.50,50.90,"1,066,710","343,305,000" 145 | "Jun 17, 2017",50.69,51.19,50.27,51.03,"1,436,890","340,842,000" 146 | "Jun 16, 2017",49.16,51.44,46.92,50.94,"1,359,210","330,219,000" 147 | "Jun 15, 2017",48.01,50.28,43.45,49.18,"1,655,390","322,219,000" 148 | "Jun 14, 2017",50.89,53.96,46.35,47.83,"1,804,340","341,224,000" 149 | "Jun 13, 2017",45.91,50.87,45.91,50.87,"1,609,630","307,656,000" 150 | "Jun 12, 2017",53.42,53.42,41.72,45.68,"2,295,830","357,687,000" 151 | "Jun 11, 2017",54.11,57.52,50.63,53.00,"1,762,110","361,918,000" 152 | "Jun 10, 2017",50.04,59.60,42.61,54.04,"3,783,760","326,419,000" 153 | "Jun 09, 2017",41.33,50.40,41.25,49.97,"2,787,430","268,196,000" 154 | "Jun 08, 2017",36.18,41.43,35.42,41.43,"2,176,920","233,903,000" 155 | "Jun 07, 2017",38.00,38.39,35.20,35.93,"3,101,570","245,393,000" 156 | "Jun 06, 2017",32.24,39.78,32.24,37.99,"2,430,580","207,988,000" 157 | "Jun 05, 2017",25.55,32.86,25.55,32.14,"2,170,880","164,708,000" 158 | "Jun 04, 2017",25.53,25.80,24.94,25.55,"1,719,260","164,484,000" 159 | "Jun 03, 2017",24.03,25.66,23.84,25.59,"2,741,120","154,747,000" 160 | "Jun 02, 2017",22.19,24.19,21.99,24.19,"1,512,120","142,856,000" 161 | "Jun 01, 2017",18.93,22.95,18.93,22.18,"2,466,910","121,713,000" 162 | "May 31, 2017",17.00,18.97,17.00,18.90,"1,228,390","109,246,000" 163 | "May 30, 2017",17.22,17.79,16.59,16.92,"801,777","110,582,000" 164 | "May 29, 2017",15.96,17.51,15.54,17.20,"825,630","102,399,000" 165 | "May 28, 2017",14.86,16.68,14.71,15.99,"405,591","95,355,900" 166 | "May 27, 2017",15.31,16.36,13.47,14.63,"551,952","98,179,600" 167 | "May 26, 2017",15.56,17.57,14.07,15.26,"591,390","99,749,800" 168 | "May 25, 2017",13.57,23.37,11.98,15.67,"6,153,930","86,953,600" 169 | "May 24, 2017",13.21,14.35,13.12,13.60,"1,025,590","84,554,600" 170 | "May 23, 2017",12.26,13.34,12.22,13.19,"662,390","78,464,700" 171 | "May 22, 2017",12.60,13.32,11.75,12.28,"834,180","80,620,000" 172 | "May 21, 2017",12.34,12.93,12.20,12.52,"545,026","78,880,200" 173 | "May 20, 2017",11.23,12.38,11.23,12.35,"653,438","71,772,600" 174 | "May 19, 2017",10.73,11.37,10.72,11.22,"670,821","68,513,600" 175 | "May 18, 2017",10.04,10.87,10.02,10.72,"819,691","64,102,400" 176 | "May 17, 2017",9.80,10.35,9.61,10.11,"783,389","62,539,500" 177 | "May 16, 2017",9.20,10.08,8.95,9.81,"765,059","58,670,700" 178 | "May 15, 2017",8.95,9.26,8.51,9.10,"496,905","57,036,400" 179 | "May 14, 2017",8.49,8.88,8.15,8.79,"397,657","54,087,400" 180 | "May 13, 2017",7.39,8.45,7.03,8.45,"480,450","47,075,500" 181 | "May 12, 2017",7.71,8.04,7.29,7.41,"448,407","49,032,700" 182 | "May 11, 2017",7.71,8.03,7.17,7.70,"407,025","49,044,900" 183 | "May 10, 2017",7.93,8.01,7.30,7.69,"499,177","50,406,400" 184 | "May 09, 2017",8.02,8.33,7.61,7.93,"704,454","50,921,800" 185 | "May 08, 2017",7.95,8.30,7.62,8.01,"808,585","50,377,900" 186 | "May 07, 2017",8.22,8.39,7.48,7.95,"266,678","51,681,300" 187 | "May 06, 2017",5.84,8.42,5.65,8.22,"875,112","36,310,900" 188 | "May 05, 2017",6.99,7.27,5.78,5.78,"566,343","43,198,800" 189 | "May 04, 2017",7.55,7.71,6.65,7.00,"556,024","46,609,100" 190 | "May 03, 2017",7.89,8.00,7.58,7.61,"716,542","48,652,600" 191 | "May 02, 2017",7.96,9.00,7.69,7.88,"578,471","49,072,400" 192 | "May 01, 2017",8.89,9.22,8.19,8.19,"483,599","54,709,600" 193 | "Apr 30, 2017",8.95,9.02,8.74,8.88,"391,218","55,090,300" 194 | "Apr 29, 2017",9.15,9.15,8.91,8.97,"557,753","56,271,900" 195 | "Apr 28, 2017",8.45,9.17,8.45,9.14,"433,870","51,889,500" 196 | "Apr 27, 2017",8.01,9.62,6.86,8.45,"715,582","49,191,200" 197 | "Apr 26, 2017",9.25,9.35,7.92,8.01,"862,259","56,757,800" 198 | "Apr 25, 2017",9.77,9.99,9.14,9.25,"615,853","59,895,000" 199 | "Apr 24, 2017",9.77,9.97,9.63,9.78,"581,280","59,861,300" 200 | "Apr 23, 2017",10.07,10.07,9.64,9.74,"294,309","61,638,000" 201 | "Apr 22, 2017",9.87,10.16,9.78,10.07,"442,488","60,365,000" 202 | "Apr 21, 2017",10.06,10.08,9.50,9.87,"474,630","61,440,400" 203 | "Apr 20, 2017",10.19,10.39,9.70,10.05,"388,381","62,223,000" 204 | "Apr 19, 2017",9.89,10.66,9.89,10.18,"495,149","60,314,300" 205 | "Apr 18, 2017",8.74,10.38,8.74,9.74,"1,048,750","53,297,500" 206 | "Apr 17, 2017",9.70,9.78,7.59,8.74,"801,362","59,082,700" 207 | "Apr 16, 2017",10.78,10.84,8.50,9.70,"737,619","65,626,200" 208 | "Apr 15, 2017",9.80,11.45,9.08,10.80,"1,077,470","58,750,800" 209 | "Apr 14, 2017",12.05,12.69,8.27,9.69,"201,720","72,172,000" 210 | "Apr 13, 2017",10.62,17.63,10.62,11.95,"1,951,160","63,522,800" 211 | "Apr 12, 2017",8.39,10.57,8.37,10.55,"902,695","50,133,900" 212 | "Apr 11, 2017",6.13,8.50,6.13,8.41,"771,597","36,618,600" 213 | "Apr 10, 2017",5.91,6.16,5.48,6.12,"595,244","35,273,600" 214 | "Apr 09, 2017",5.73,6.20,5.73,5.92,"470,292","34,156,000" 215 | "Apr 08, 2017",5.43,5.80,5.36,5.73,"458,324","32,329,000" 216 | "Apr 07, 2017",5.17,5.51,5.02,5.45,"614,199","30,770,800" 217 | "Apr 06, 2017",4.80,5.22,4.80,5.20,"499,333","28,510,400" 218 | "Apr 05, 2017",4.77,4.81,4.66,4.79,"355,818","28,317,800" 219 | "Apr 04, 2017",4.49,4.85,4.43,4.76,"398,884","26,668,800" 220 | "Apr 03, 2017",3.91,4.66,3.91,4.42,"414,450","23,190,700" 221 | "Apr 02, 2017",4.02,4.23,3.88,3.91,"149,998","23,780,900" 222 | "Apr 01, 2017",3.53,4.04,3.49,4.01,"432,916","20,858,600" 223 | "Mar 31, 2017",3.35,3.59,3.34,3.49,"277,557","19,395,400" 224 | "Mar 30, 2017",3.41,3.43,3.30,3.35,"313,656","19,700,100" 225 | "Mar 29, 2017",3.34,3.44,3.25,3.40,"250,322","19,176,200" 226 | "Mar 28, 2017",3.25,3.40,3.23,3.34,"340,582","18,635,300" 227 | "Mar 27, 2017",2.99,3.29,2.93,3.25,"303,282","17,109,800" 228 | "Mar 26, 2017",3.05,3.15,2.90,2.97,"165,270","17,464,100" 229 | "Mar 25, 2017",2.70,4.42,2.34,3.04,"377,669","15,418,900" 230 | "Mar 24, 2017",2.02,3.91,2.01,3.32,"347,994","11,530,000" 231 | "Mar 23, 2017",1.83,2.08,1.78,2.02,"244,700","10,431,300" 232 | "Mar 22, 2017",1.89,1.94,1.77,1.83,"162,423","10,741,700" 233 | "Mar 21, 2017",1.79,1.95,1.77,1.89,"248,776","10,195,800" 234 | "Mar 20, 2017",1.74,1.80,1.70,1.79,"261,732","9,891,750" 235 | "Mar 19, 2017",1.61,1.79,1.59,1.74,"200,786","9,129,360" 236 | "Mar 18, 2017",1.73,1.77,1.54,1.60,"233,726","9,815,210" 237 | "Mar 17, 2017",1.83,1.90,1.73,1.73,"239,185","10,355,500" 238 | "Mar 16, 2017",1.89,1.94,1.76,1.84,"231,056","10,683,100" 239 | "Mar 15, 2017",1.89,1.98,1.86,1.89,"296,537","10,676,500" 240 | "Mar 14, 2017",1.86,1.97,1.86,1.89,"197,787","10,499,500" 241 | "Mar 13, 2017",1.74,1.99,1.72,1.86,"207,174","9,805,420" 242 | "Mar 12, 2017",1.88,2.00,1.66,1.73,"209,145","10,574,100" 243 | "Mar 11, 2017",1.65,2.04,1.65,1.88,"329,288","8,976,540" 244 | "Mar 10, 2017",1.57,1.96,1.57,1.65,"231,193","8,538,000" 245 | "Mar 09, 2017",0.910759,6.90,0.904785,1.57,"391,543","4,953,980" 246 | "Mar 08, 2017",0.928324,2.29,0.892919,0.910482,"80,489","5,043,800" 247 | "Mar 07, 2017",0.929928,0.965031,0.902599,0.928556,"112,631","5,046,350" 248 | "Mar 06, 2017",0.877932,0.948389,0.877303,0.929657,"144,511","4,758,800" 249 | "Mar 05, 2017",0.860446,0.890336,0.854322,0.877690,"99,353","4,658,870" 250 | "Mar 04, 2017",0.876560,0.901431,0.848197,0.861036,"118,768","4,741,050" 251 | "Mar 03, 2017",0.849622,0.897957,0.849622,0.874886,"133,898","4,588,430" 252 | "Mar 02, 2017",0.843463,0.867530,0.833101,0.849830,"112,199","4,549,750" 253 | "Mar 01, 2017",0.804026,0.847651,0.803913,0.841962,"94,260","4,332,560" 254 | "Feb 28, 2017",0.805227,0.831538,0.797892,0.803977,"107,824","4,333,750" 255 | "Feb 27, 2017",0.798417,0.819324,0.798143,0.804716,"71,439","4,292,460" 256 | "Feb 26, 2017",0.780171,0.814878,0.769603,0.799392,"75,564","4,190,100" 257 | "Feb 25, 2017",0.798545,0.821233,0.764979,0.779878,"96,943","4,283,810" 258 | "Feb 24, 2017",0.720091,0.833797,0.710127,0.800726,"80,798","3,858,450" 259 | "Feb 23, 2017",0.750903,0.800626,0.697684,0.716413,"104,601","4,018,590" 260 | "Feb 22, 2017",0.765145,0.800321,0.663462,0.751017,"102,991","4,088,710" 261 | "Feb 21, 2017",0.743569,0.788681,0.742046,0.765488,"46,477","3,968,830" 262 | "Feb 20, 2017",0.722645,0.744402,0.718499,0.744051,"79,052","3,845,050" 263 | "Feb 19, 2017",0.723668,0.759755,0.718855,0.722082,"17,807","3,840,990" 264 | "Feb 18, 2017",0.714177,0.770619,0.712649,0.723435,"69,567","3,786,090" 265 | "Feb 17, 2017",0.737502,0.765716,0.711911,0.712135,"73,305","3,905,080" 266 | "Feb 16, 2017",0.726066,0.762640,0.725988,0.738451,"64,234","3,839,920" 267 | "Feb 15, 2017",0.731512,0.748031,0.721461,0.725943,"84,565","3,864,230" 268 | "Feb 14, 2017",0.711982,0.744774,0.665671,0.730306,"84,926","3,756,710" 269 | "Feb 13, 2017",0.696483,0.718306,0.615641,0.711195,"100,391","3,670,810" 270 | "Feb 12, 2017",0.701552,0.724620,0.693313,0.696708,"90,321","3,693,230" 271 | "Feb 11, 2017",0.634346,0.728807,0.621720,0.702202,"73,165","3,335,540" 272 | "Feb 10, 2017",0.567441,0.652978,0.546511,0.634202,"136,220","2,979,990" 273 | "Feb 09, 2017",0.574614,0.635086,0.529744,0.566729,"40,765","3,013,100" 274 | "Feb 08, 2017",0.425789,0.620504,0.425789,0.573734,"97,396","2,230,210" 275 | "Feb 07, 2017",0.447859,0.516073,0.422868,0.425400,"65,544","2,343,170" 276 | "Feb 06, 2017",0.465675,0.531860,0.445042,0.447002,"92,361","2,372,230" 277 | "Feb 05, 2017",0.568783,0.594951,0.465195,0.465195,"22,814","2,893,950" 278 | "Feb 04, 2017",0.513954,0.618865,0.511836,0.568446,"41,471","2,611,770" 279 | "Feb 03, 2017",0.424369,0.616739,0.423258,0.513246,"104,851","2,151,070" 280 | "Feb 02, 2017",0.376986,0.510052,0.374696,0.424510,"49,021","1,908,590" 281 | "Feb 01, 2017",0.234603,0.625286,0.234330,0.380666,"70,857","1,186,290" 282 | "Jan 31, 2017",0.201900,0.248894,0.192904,0.234476,"38,955","1,019,790" 283 | "Jan 30, 2017",0.183540,0.211474,0.183411,0.201773,"25,986","926,047" 284 | "Jan 29, 2017",0.185211,0.191636,0.178000,0.183409,"10,832","933,414" 285 | "Jan 28, 2017",0.167891,0.191118,0.167889,0.185115,"12,342","845,152" 286 | "Jan 27, 2017",0.162051,0.242873,0.151854,0.167880,"24,828","814,864" 287 | "Jan 26, 2017",0.154363,0.179255,0.147483,0.161915,"9,966","775,361" 288 | "Jan 25, 2017",0.142849,0.313312,0.142811,0.154217,"14,945","716,763" 289 | "Jan 24, 2017",0.152959,0.671748,0.134264,0.142972,"33,237","766,670" 290 | "Jan 23, 2017",0.128182,0.156983,0.126968,0.154695,"6,921","641,762" 291 | "Jan 22, 2017",0.174903,0.178088,0.123697,0.128067,526,"874,666" 292 | "Jan 21, 2017",0.145710,0.236289,0.144554,0.174829,"12,872","727,753" 293 | "Jan 20, 2017",0.162671,0.166808,0.145625,0.145625,"5,978","812,236" 294 | -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/debug_always_buy_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open 2 | "Nov 01, 2017",6.0 3 | "Nov 02, 2017",7.0 4 | "Nov 03, 2017",8.0 5 | "Nov 04, 2017",9.0 6 | "Nov 05, 2017",10.0 -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/debug_buy_sell_hold_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open 2 | "Nov 01, 2017",5.0 3 | "Nov 02, 2017",6.0 4 | "Nov 03, 2017",8.0 5 | "Nov 04, 2017",6.0 6 | "Nov 05, 2017",5.0 -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/debug_never_buy_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open 2 | "Nov 01, 2017",10.0 3 | "Nov 02, 2017",9.0 4 | "Nov 03, 2017",8.0 5 | "Nov 04, 2017",7.0 6 | "Nov 05, 2017",6.0 -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/iota_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",0.371509,0.397608,0.362284,0.383096,"15,415,700","1,032,620,000" 3 | "Nov 06, 2017",0.351011,0.378777,0.338867,0.373939,"13,258,400","975,647,000" 4 | "Nov 05, 2017",0.367915,0.370910,0.335194,0.350084,"12,950,500","1,022,630,000" 5 | "Nov 04, 2017",0.391327,0.391546,0.365428,0.368643,"8,568,260","1,087,700,000" 6 | "Nov 03, 2017",0.362970,0.396015,0.358817,0.393126,"11,427,900","1,008,890,000" 7 | "Nov 02, 2017",0.370966,0.380213,0.320862,0.366056,"20,942,000","1,031,110,000" 8 | "Nov 01, 2017",0.390863,0.390863,0.356690,0.363920,"11,944,600","1,086,410,000" 9 | "Oct 31, 2017",0.407912,0.408340,0.390312,0.390915,"7,839,910","1,133,800,000" 10 | "Oct 30, 2017",0.403103,0.415571,0.385603,0.409046,"9,124,580","1,120,440,000" 11 | "Oct 29, 2017",0.395947,0.413541,0.367674,0.403720,"15,972,200","1,100,550,000" 12 | "Oct 28, 2017",0.424433,0.428173,0.391215,0.395483,"9,075,000","1,179,720,000" 13 | "Oct 27, 2017",0.416744,0.439441,0.395594,0.423355,"8,963,410","1,158,350,000" 14 | "Oct 26, 2017",0.443666,0.455887,0.411928,0.417107,"10,747,100","1,233,180,000" 15 | "Oct 25, 2017",0.455356,0.473467,0.430005,0.443448,"14,379,600","1,265,680,000" 16 | "Oct 24, 2017",0.389144,0.502278,0.377494,0.453682,"47,178,400","1,081,640,000" 17 | "Oct 23, 2017",0.391371,0.399234,0.364940,0.386487,"12,380,800","1,087,830,000" 18 | "Oct 22, 2017",0.390836,0.411999,0.381438,0.392542,"9,322,400","1,086,340,000" 19 | "Oct 21, 2017",0.403854,0.406504,0.324360,0.393045,"20,120,500","1,122,530,000" 20 | "Oct 20, 2017",0.432863,0.435639,0.391630,0.401913,"17,771,900","1,203,160,000" 21 | "Oct 19, 2017",0.457196,0.465953,0.415102,0.433388,"12,250,600","1,270,790,000" 22 | "Oct 18, 2017",0.474621,0.482291,0.427958,0.454575,"12,433,700","1,319,220,000" 23 | "Oct 17, 2017",0.452052,0.504408,0.434911,0.468463,"12,590,200","1,256,490,000" 24 | "Oct 16, 2017",0.439699,0.459618,0.423750,0.450655,"8,128,940","1,222,160,000" 25 | "Oct 15, 2017",0.458649,0.460506,0.414704,0.438429,"8,256,490","1,274,830,000" 26 | "Oct 14, 2017",0.441808,0.482837,0.431503,0.457837,"11,493,700","1,228,020,000" 27 | "Oct 13, 2017",0.412854,0.445985,0.403912,0.441595,"14,821,100","1,147,540,000" 28 | "Oct 12, 2017",0.481734,0.486223,0.391482,0.412417,"16,792,100","1,338,990,000" 29 | "Oct 11, 2017",0.477029,0.488967,0.464757,0.481464,"6,996,130","1,325,920,000" 30 | "Oct 10, 2017",0.466453,0.488517,0.452723,0.477576,"7,401,800","1,296,520,000" 31 | "Oct 09, 2017",0.500356,0.501909,0.439523,0.469438,"18,097,100","1,390,760,000" 32 | "Oct 08, 2017",0.534649,0.538526,0.492876,0.500032,"9,637,830","1,486,070,000" 33 | "Oct 07, 2017",0.504488,0.548719,0.490615,0.538529,"9,848,850","1,402,240,000" 34 | "Oct 06, 2017",0.543216,0.562671,0.493282,0.503448,"12,478,500","1,509,890,000" 35 | "Oct 05, 2017",0.547394,0.567734,0.520702,0.540915,"7,592,760","1,521,500,000" 36 | "Oct 04, 2017",0.560853,0.570545,0.520099,0.546982,"9,152,780","1,558,910,000" 37 | "Oct 03, 2017",0.577182,0.582044,0.516038,0.561712,"13,709,400","1,604,290,000" 38 | "Oct 02, 2017",0.618180,0.622090,0.565055,0.575398,"13,928,300","1,718,250,000" 39 | "Oct 01, 2017",0.621750,0.628776,0.592742,0.610183,"8,576,220","1,728,170,000" 40 | "Sep 30, 2017",0.584318,0.646884,0.576150,0.620822,"21,825,700","1,624,130,000" 41 | "Sep 29, 2017",0.595143,0.609587,0.543016,0.584418,"16,689,800","1,654,220,000" 42 | "Sep 28, 2017",0.549661,0.614313,0.528270,0.595896,"23,776,300","1,527,800,000" 43 | "Sep 27, 2017",0.514224,0.554709,0.507709,0.551005,"12,188,400","1,429,300,000" 44 | "Sep 26, 2017",0.556670,0.560043,0.507645,0.515205,"14,671,500","1,547,280,000" 45 | "Sep 25, 2017",0.524449,0.566395,0.524449,0.556207,"10,506,400","1,457,720,000" 46 | "Sep 24, 2017",0.540538,0.541688,0.506966,0.521379,"9,199,830","1,502,440,000" 47 | "Sep 23, 2017",0.507613,0.551145,0.494903,0.541796,"8,486,720","1,410,930,000" 48 | "Sep 22, 2017",0.499185,0.517458,0.476075,0.506010,"8,860,800","1,387,500,000" 49 | "Sep 21, 2017",0.567586,0.569993,0.467953,0.500724,"18,553,300","1,577,620,000" 50 | "Sep 20, 2017",0.559849,0.585680,0.543853,0.566627,"8,802,430","1,556,120,000" 51 | "Sep 19, 2017",0.608275,0.614231,0.555303,0.565168,"12,972,000","1,690,720,000" 52 | "Sep 18, 2017",0.496796,0.612485,0.496796,0.606233,"28,609,000","1,380,860,000" 53 | "Sep 17, 2017",0.484758,0.505875,0.462614,0.497046,"7,574,760","1,347,400,000" 54 | "Sep 16, 2017",0.479385,0.510361,0.453232,0.487239,"13,452,000","1,332,470,000" 55 | "Sep 15, 2017",0.445700,0.509332,0.372595,0.480510,"41,983,100","1,238,840,000" 56 | "Sep 14, 2017",0.565841,0.573630,0.445019,0.445019,"25,946,400","1,572,770,000" 57 | "Sep 13, 2017",0.592512,0.595366,0.479349,0.556820,"31,807,500","1,646,910,000" 58 | "Sep 12, 2017",0.561696,0.647193,0.557297,0.591949,"43,345,900","1,561,250,000" 59 | "Sep 11, 2017",0.498380,0.558273,0.481498,0.558273,"23,660,500","1,385,260,000" 60 | "Sep 10, 2017",0.561304,0.567870,0.462834,0.495607,"32,733,100","1,560,160,000" 61 | "Sep 09, 2017",0.525939,0.583964,0.524823,0.560809,"15,317,400","1,461,860,000" 62 | "Sep 08, 2017",0.648249,0.660258,0.490346,0.540475,"48,691,600","1,801,830,000" 63 | "Sep 07, 2017",0.739668,0.739668,0.622366,0.645758,"31,377,000","2,055,930,000" 64 | "Sep 06, 2017",0.613529,0.749172,0.601484,0.741663,"33,093,300","1,705,320,000" 65 | "Sep 05, 2017",0.544132,0.646085,0.468949,0.613085,"45,817,500","1,512,430,000" 66 | "Sep 04, 2017",0.744257,0.744257,0.406795,0.566472,"74,601,300","2,068,680,000" 67 | "Sep 03, 2017",0.698855,0.775863,0.672850,0.743968,"29,504,600","1,942,490,000" 68 | "Sep 02, 2017",0.796560,0.802464,0.658006,0.695547,"39,333,900","2,214,060,000" 69 | "Sep 01, 2017",0.842867,0.879100,0.768119,0.807778,"28,047,000","2,342,770,000" 70 | "Aug 31, 2017",0.869553,0.902074,0.828224,0.842424,"15,194,300","2,416,950,000" 71 | "Aug 30, 2017",0.812777,0.878203,0.792339,0.869647,"17,428,100","2,259,140,000" 72 | "Aug 29, 2017",0.876892,0.877578,0.746405,0.811961,"28,538,500","2,437,350,000" 73 | "Aug 28, 2017",0.922464,0.927742,0.784779,0.875197,"24,288,200","2,564,020,000" 74 | "Aug 27, 2017",0.962058,0.979088,0.887365,0.920351,"17,816,000","2,674,070,000" 75 | "Aug 26, 2017",0.915926,0.970068,0.877886,0.962213,"16,623,100","2,545,840,000" 76 | "Aug 25, 2017",0.894733,0.934651,0.837866,0.919635,"18,226,300","2,486,940,000" 77 | "Aug 24, 2017",0.854043,0.895101,0.813880,0.895101,"17,132,900","2,373,840,000" 78 | "Aug 23, 2017",0.842517,0.940389,0.834667,0.850371,"27,418,300","2,341,800,000" 79 | "Aug 22, 2017",0.901778,0.901778,0.786259,0.843775,"26,333,800","2,506,520,000" 80 | "Aug 21, 2017",0.907423,0.939166,0.843577,0.906269,"32,558,600","2,522,210,000" 81 | "Aug 20, 2017",0.971222,1.02,0.939619,0.942205,"29,447,600","2,699,540,000" 82 | "Aug 19, 2017",0.871580,0.985748,0.778133,0.978521,"39,975,500","2,422,580,000" 83 | "Aug 18, 2017",1.01,1.03,0.774400,0.870147,"58,053,400","2,819,080,000" 84 | "Aug 17, 2017",1.04,1.10,0.998241,1.02,"58,209,300","2,904,020,000" 85 | "Aug 16, 2017",0.914727,1.05,0.878567,1.05,"52,081,500","2,542,510,000" 86 | "Aug 15, 2017",0.977320,0.995791,0.767236,0.917949,"84,698,300","2,716,490,000" 87 | "Aug 14, 2017",0.811738,0.976404,0.793682,0.976404,"54,630,900","2,256,250,000" 88 | "Aug 13, 2017",0.722169,0.829530,0.715382,0.807713,"41,198,400","2,007,290,000" 89 | "Aug 12, 2017",0.655191,0.727960,0.625521,0.721535,"20,358,000","1,821,120,000" 90 | "Aug 11, 2017",0.565525,0.710585,0.557827,0.654872,"43,618,800","1,571,890,000" 91 | "Aug 10, 2017",0.535805,0.588071,0.513250,0.566456,"16,602,500","1,489,290,000" 92 | "Aug 09, 2017",0.547121,0.555125,0.512566,0.543328,"13,294,400","1,520,740,000" 93 | "Aug 08, 2017",0.473874,0.550880,0.458992,0.547637,"21,988,500","1,317,150,000" 94 | "Aug 07, 2017",0.430804,0.491028,0.418088,0.474577,"14,717,700","1,197,430,000" 95 | "Aug 06, 2017",0.407690,0.440193,0.396851,0.431142,"6,276,510","1,133,190,000" 96 | "Aug 05, 2017",0.393176,0.427798,0.364083,0.407980,"9,091,140","1,092,850,000" 97 | "Aug 04, 2017",0.332239,0.420252,0.332239,0.391286,"20,179,000","923,468,000" 98 | "Aug 03, 2017",0.286578,0.336844,0.284765,0.332352,"8,239,810","796,552,000" 99 | "Aug 02, 2017",0.290135,0.293039,0.272032,0.286116,"3,439,800","806,440,000" 100 | "Aug 01, 2017",0.256665,0.296267,0.249623,0.290220,"5,169,910","713,408,000" 101 | "Jul 31, 2017",0.255064,0.259810,0.245768,0.254732,"2,563,820","708,959,000" 102 | "Jul 30, 2017",0.277339,0.279401,0.252831,0.254785,"3,165,840","770,872,000" 103 | "Jul 29, 2017",0.266567,0.277226,0.245848,0.275190,"2,788,270","740,931,000" 104 | "Jul 28, 2017",0.274876,0.278459,0.262736,0.265118,"2,884,740","764,026,000" 105 | "Jul 27, 2017",0.276850,0.285551,0.275467,0.275467,"3,343,540","769,512,000" 106 | "Jul 26, 2017",0.250571,0.283478,0.241237,0.274598,"4,626,790","696,469,000" 107 | "Jul 25, 2017",0.266827,0.269072,0.237998,0.250453,"2,917,500","741,654,000" 108 | "Jul 24, 2017",0.265136,0.273468,0.242731,0.266447,"4,502,060","736,952,000" 109 | "Jul 23, 2017",0.273693,0.280241,0.258485,0.269072,"3,065,860","760,738,000" 110 | "Jul 22, 2017",0.263390,0.278936,0.254406,0.273382,"4,107,430","732,099,000" 111 | "Jul 21, 2017",0.294760,0.305506,0.257626,0.264134,"6,344,870","819,295,000" 112 | "Jul 20, 2017",0.233503,0.298253,0.232192,0.292460,"10,332,500","649,028,000" 113 | "Jul 19, 2017",0.268162,0.284031,0.230686,0.232212,"6,339,730","745,365,000" 114 | "Jul 18, 2017",0.264569,0.309577,0.248754,0.267340,"11,433,600","735,378,000" 115 | "Jul 17, 2017",0.180717,0.278088,0.179114,0.263105,"15,254,300","502,309,000" 116 | "Jul 16, 2017",0.157961,0.185445,0.155173,0.180978,"4,178,170","439,057,000" 117 | "Jul 15, 2017",0.175237,0.176099,0.147933,0.158688,"3,913,220","487,076,000" 118 | "Jul 14, 2017",0.212999,0.214112,0.161877,0.175350,"3,347,860","592,038,000" 119 | "Jul 13, 2017",0.229099,0.238625,0.194249,0.214589,"4,129,150","636,787,000" 120 | "Jul 12, 2017",0.191125,0.237362,0.183955,0.228758,"4,646,480","531,237,000" 121 | "Jul 11, 2017",0.214742,0.231574,0.185681,0.187596,"6,946,200","596,881,000" 122 | "Jul 10, 2017",0.304476,0.304476,0.190539,0.217061,"8,233,640","846,301,000" 123 | "Jul 09, 2017",0.297377,0.312770,0.285475,0.302889,"2,474,500","826,569,000" 124 | "Jul 08, 2017",0.286164,0.320908,0.281393,0.305515,"3,273,950","795,402,000" 125 | "Jul 07, 2017",0.355803,0.355994,0.271859,0.284565,"8,804,780","988,966,000" 126 | "Jul 06, 2017",0.380253,0.382865,0.317295,0.353880,"8,218,370","1,056,920,000" 127 | "Jul 05, 2017",0.396273,0.400841,0.371809,0.380130,"3,061,100","1,101,450,000" 128 | "Jul 04, 2017",0.374900,0.410698,0.373865,0.396390,"3,933,710","1,042,050,000" 129 | "Jul 03, 2017",0.379055,0.384955,0.356024,0.376139,"3,873,180","1,053,600,000" 130 | "Jul 02, 2017",0.391880,0.396890,0.366798,0.382249,"2,971,770","1,089,240,000" 131 | "Jul 01, 2017",0.402295,0.414192,0.381489,0.389630,"2,334,640","1,118,190,000" 132 | "Jun 30, 2017",0.417167,0.453008,0.398195,0.401591,"5,044,270","1,159,530,000" 133 | "Jun 29, 2017",0.375767,0.459387,0.361568,0.417798,"5,324,020","1,044,460,000" 134 | "Jun 28, 2017",0.399874,0.399874,0.357338,0.379136,"4,704,400","1,111,460,000" 135 | "Jun 27, 2017",0.411989,0.420035,0.353549,0.392269,"4,411,090","1,145,140,000" 136 | "Jun 26, 2017",0.470192,0.473662,0.351156,0.402438,"9,101,080","1,306,910,000" 137 | "Jun 25, 2017",0.514185,0.525564,0.454951,0.470941,"5,012,890","1,429,190,000" 138 | "Jun 24, 2017",0.482769,0.635612,0.482769,0.512910,"19,215,500","1,341,870,000" 139 | "Jun 23, 2017",0.417769,0.480910,0.408405,0.480910,"3,768,560","1,161,200,000" 140 | "Jun 22, 2017",0.413371,0.427283,0.407261,0.417742,"2,343,320","1,148,980,000" 141 | "Jun 21, 2017",0.419439,0.437340,0.405037,0.413547,"3,999,810","1,165,840,000" 142 | "Jun 20, 2017",0.414299,0.422032,0.398649,0.418494,"3,755,470","1,151,560,000" 143 | "Jun 19, 2017",0.405456,0.420990,0.388231,0.412183,"3,543,640","1,126,980,000" 144 | "Jun 18, 2017",0.420597,0.426069,0.393790,0.405862,"2,514,450","1,169,060,000" 145 | "Jun 17, 2017",0.426762,0.444205,0.414139,0.419906,"3,100,660","1,186,200,000" 146 | "Jun 16, 2017",0.353285,0.448249,0.309852,0.410757,"6,920,690","981,966,000" 147 | "Jun 15, 2017",0.528284,0.543165,0.300365,0.363661,"10,300,400","1,468,380,000" 148 | "Jun 14, 2017",0.592347,0.606196,0.495745,0.528916,"14,194,900","1,646,450,000" 149 | "Jun 13, 2017",0.638503,0.652862,0.533910,0.590255,"25,425,600","1,774,740,000" 150 | -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/numeraire_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",10.77,11.27,10.17,10.60,"121,944","13,444,500" 3 | "Nov 06, 2017",11.26,11.53,10.57,10.78,"57,204","14,062,200" 4 | "Nov 05, 2017",11.45,12.89,10.74,10.95,"185,214","14,298,300" 5 | "Nov 04, 2017",12.45,13.36,10.84,11.47,"334,820","15,548,300" 6 | "Nov 03, 2017",9.15,13.75,8.97,12.48,"482,650","11,423,500" 7 | "Nov 02, 2017",10.28,10.42,8.62,9.76,"205,052","12,832,100" 8 | "Nov 01, 2017",11.64,12.36,9.82,10.44,"230,197","14,534,400" 9 | "Oct 31, 2017",12.87,13.07,11.59,11.66,"163,423","16,067,000" 10 | "Oct 30, 2017",11.55,13.60,11.52,12.91,"178,535","14,416,700" 11 | "Oct 29, 2017",12.14,13.77,11.40,11.46,"259,423","15,160,800" 12 | "Oct 28, 2017",12.19,12.75,11.01,12.25,"148,762","15,218,000" 13 | "Oct 27, 2017",12.07,12.55,11.04,12.16,"139,761","15,071,400" 14 | "Oct 26, 2017",12.53,12.53,11.53,12.07,"65,175","15,647,800" 15 | "Oct 25, 2017",13.13,13.15,11.19,12.60,"77,863","16,393,000" 16 | "Oct 24, 2017",11.72,14.03,10.96,13.12,"118,312","14,637,400" 17 | "Oct 23, 2017",11.98,13.44,11.06,11.75,"115,467","14,957,400" 18 | "Oct 22, 2017",12.64,13.16,11.79,12.00,"50,124","15,788,900" 19 | "Oct 21, 2017",14.11,15.22,12.06,12.74,"129,563","17,616,500" 20 | "Oct 20, 2017",14.70,17.58,13.79,14.14,"434,935","18,349,500" 21 | "Oct 19, 2017",14.30,15.18,12.56,14.46,"209,523","17,851,900" 22 | "Oct 18, 2017",13.92,15.84,12.48,14.47,"356,003","17,384,800" 23 | "Oct 17, 2017",12.63,16.77,11.72,13.72,"480,549","15,775,200" 24 | "Oct 16, 2017",10.89,14.39,10.47,12.17,"332,447","13,599,700" 25 | "Oct 15, 2017",11.29,11.76,10.60,10.89,"64,751","14,102,400" 26 | "Oct 14, 2017",11.82,12.32,10.41,11.37,"228,223","14,754,900" 27 | "Oct 13, 2017",12.12,14.52,10.95,11.81,"518,327","15,127,600" 28 | "Oct 12, 2017",12.12,16.12,11.27,12.10,"945,572","15,128,000" 29 | "Oct 11, 2017",11.48,13.80,10.95,12.36,"205,337","14,343,600" 30 | "Oct 10, 2017",11.55,11.92,10.60,11.48,"112,363","14,430,000" 31 | "Oct 09, 2017",12.11,13.82,10.88,11.55,"184,017","15,121,100" 32 | "Oct 08, 2017",14.65,15.11,11.99,12.10,"256,490","18,293,100" 33 | "Oct 07, 2017",14.65,14.96,14.08,14.87,"145,223","18,295,100" 34 | "Oct 06, 2017",14.22,15.36,14.16,14.64,"91,720","17,754,300" 35 | "Oct 05, 2017",14.12,15.42,13.32,14.22,"220,070","17,635,900" 36 | "Oct 04, 2017",13.84,15.36,13.41,14.11,"240,893","17,295,800" 37 | "Oct 03, 2017",14.95,15.10,13.39,13.81,"149,112","18,683,000" 38 | "Oct 02, 2017",16.36,16.92,13.96,14.79,"467,244","20,440,100" 39 | "Oct 01, 2017",14.72,17.08,13.45,16.36,"298,959","18,394,200" 40 | "Sep 30, 2017",14.73,15.57,14.54,14.56,"69,376","18,409,000" 41 | "Sep 29, 2017",15.41,15.42,14.08,14.73,"135,492","19,254,500" 42 | "Sep 28, 2017",17.02,17.05,14.99,15.42,"125,586","21,268,800" 43 | "Sep 27, 2017",15.03,17.19,14.70,16.91,"277,008","18,785,600" 44 | "Sep 26, 2017",15.38,15.73,14.77,15.15,"143,434","19,222,600" 45 | "Sep 25, 2017",15.53,16.09,14.24,15.34,"287,753","19,416,300" 46 | "Sep 24, 2017",13.73,16.62,13.20,15.53,"686,526","17,157,200" 47 | "Sep 23, 2017",13.00,14.00,12.79,13.73,"124,841","16,252,500" 48 | "Sep 22, 2017",13.15,13.91,12.73,13.16,"55,768","16,441,500" 49 | "Sep 21, 2017",15.15,15.15,12.78,13.17,"170,853","18,936,100" 50 | "Sep 20, 2017",15.58,16.12,14.75,15.22,"160,192","19,478,000" 51 | "Sep 19, 2017",17.00,17.00,15.31,15.60,"149,142","21,252,800" 52 | "Sep 18, 2017",16.56,17.95,15.42,16.96,"219,636","20,703,500" 53 | "Sep 17, 2017",15.52,16.81,14.72,16.59,"74,804","19,409,800" 54 | "Sep 16, 2017",17.03,17.03,14.92,15.54,"106,754","21,290,500" 55 | "Sep 15, 2017",13.53,17.18,12.28,17.07,"229,961","16,919,700" 56 | "Sep 14, 2017",17.15,17.49,13.43,13.43,"208,388","21,435,700" 57 | "Sep 13, 2017",18.93,18.93,15.94,17.12,"311,553","23,673,000" 58 | "Sep 12, 2017",19.24,20.09,17.44,19.09,"398,928","24,063,900" 59 | "Sep 11, 2017",21.48,21.48,18.04,18.98,"335,702","26,868,700" 60 | "Sep 10, 2017",23.04,27.28,19.26,21.24,"1,448,320","28,821,700" 61 | "Sep 09, 2017",19.17,25.34,17.42,22.97,"1,345,530","23,977,600" 62 | "Sep 08, 2017",21.53,23.25,18.28,19.13,"305,855","26,935,100" 63 | "Sep 07, 2017",22.34,23.16,20.41,21.53,"262,532","27,947,600" 64 | "Sep 06, 2017",21.64,26.31,20.75,22.38,"473,273","27,076,900" 65 | "Sep 05, 2017",20.87,23.62,18.91,21.53,"349,885","26,115,800" 66 | "Sep 04, 2017",26.91,27.34,17.99,20.74,"716,231","33,673,500" 67 | "Sep 03, 2017",27.70,29.36,24.99,26.90,"493,926","34,662,300" 68 | "Sep 02, 2017",32.49,33.01,26.79,27.24,"633,861","40,658,600" 69 | "Sep 01, 2017",35.67,35.90,31.35,32.45,"1,024,920","44,636,600" 70 | "Aug 31, 2017",35.78,36.60,34.27,35.62,"452,411","44,776,600" 71 | "Aug 30, 2017",34.89,38.40,34.61,35.84,"549,569","43,694,000" 72 | "Aug 29, 2017",36.12,36.84,34.43,34.92,"489,247","45,236,000" 73 | "Aug 28, 2017",35.56,36.20,34.11,36.07,"402,594","44,537,800" 74 | "Aug 27, 2017",35.16,36.33,34.05,35.53,"372,296","44,033,500" 75 | "Aug 26, 2017",35.31,37.01,33.54,34.93,"363,769","44,220,200" 76 | "Aug 25, 2017",35.51,37.67,32.94,35.24,"845,188","44,468,400" 77 | "Aug 24, 2017",35.60,37.29,34.84,35.39,"466,415","44,577,800" 78 | "Aug 23, 2017",35.53,38.34,34.85,36.49,"443,443","44,506,600" 79 | "Aug 22, 2017",34.75,37.23,31.91,35.61,"561,611","43,526,300" 80 | "Aug 21, 2017",42.41,48.73,33.48,34.58,"2,145,180","53,121,100" 81 | "Aug 20, 2017",34.73,43.36,32.52,42.53,"1,894,140","43,499,200" 82 | "Aug 19, 2017",35.56,37.01,31.60,34.84,"582,704","44,542,600" 83 | "Aug 18, 2017",34.17,39.43,31.88,35.03,"1,612,640","42,797,100" 84 | "Aug 17, 2017",33.79,36.14,31.85,33.92,"739,864","42,325,000" 85 | "Aug 16, 2017",31.27,37.92,30.37,33.62,"864,797","39,176,900" 86 | "Aug 15, 2017",34.85,36.10,30.67,31.23,"763,238","43,659,400" 87 | "Aug 14, 2017",36.80,38.09,32.76,34.65,"763,860","46,104,500" 88 | "Aug 13, 2017",43.83,46.78,33.13,36.78,"1,431,600","54,913,000" 89 | "Aug 12, 2017",34.64,47.85,32.80,43.37,"2,680,510","43,392,300" 90 | "Aug 11, 2017",26.46,41.47,26.06,33.64,"3,202,390","33,143,700" 91 | "Aug 10, 2017",28.84,29.21,26.46,26.46,"748,370","36,136,200" 92 | "Aug 09, 2017",27.96,33.04,26.79,29.24,"1,128,830","35,034,100" 93 | "Aug 08, 2017",27.86,28.34,25.22,27.97,"521,900","34,067,900" 94 | "Aug 07, 2017",28.32,30.01,26.70,27.93,"456,117","34,625,700" 95 | "Aug 06, 2017",29.42,29.76,27.60,28.38,"386,351","35,980,100" 96 | "Aug 05, 2017",26.66,30.41,26.59,29.25,"558,040","32,606,100" 97 | "Aug 04, 2017",26.80,28.27,26.47,26.63,"403,184","32,772,500" 98 | "Aug 03, 2017",26.26,28.38,25.59,27.17,"320,060","32,107,700" 99 | "Aug 02, 2017",26.15,29.96,24.75,26.23,"551,211","31,986,000" 100 | "Aug 01, 2017",25.65,30.04,24.18,26.17,"305,623","31,374,200" 101 | "Jul 31, 2017",26.01,26.47,24.69,25.28,"166,615","31,810,000" 102 | "Jul 30, 2017",25.88,27.32,24.76,26.51,"116,912","31,649,900" 103 | "Jul 29, 2017",25.28,26.29,24.13,25.87,"120,964","30,920,300" 104 | "Jul 28, 2017",27.72,28.26,24.15,25.37,"214,957","33,899,000" 105 | "Jul 27, 2017",27.48,28.43,26.25,27.64,"163,616","33,610,800" 106 | "Jul 26, 2017",27.65,28.93,24.75,26.97,"323,792","33,814,100" 107 | "Jul 25, 2017",33.69,33.89,25.92,27.29,"460,800","41,210,000" 108 | "Jul 24, 2017",33.01,36.16,32.04,33.69,"551,830","40,370,800" 109 | "Jul 23, 2017",36.59,37.54,32.41,32.89,"515,553","44,748,100" 110 | "Jul 22, 2017",34.14,41.15,33.96,36.59,"909,922","41,751,100" 111 | "Jul 21, 2017",35.87,38.40,33.27,34.14,"320,166","43,866,500" 112 | "Jul 20, 2017",27.93,39.44,26.73,35.54,"1,116,080","34,174,900" 113 | "Jul 19, 2017",25.08,35.93,23.53,28.23,"1,959,790","30,689,100" 114 | "Jul 18, 2017",23.11,29.48,20.47,25.31,"550,981","28,272,600" 115 | "Jul 17, 2017",17.46,22.79,17.46,22.69,"272,026","21,363,400" 116 | "Jul 16, 2017",18.99,20.06,16.54,17.49,"213,544","23,236,900" 117 | "Jul 15, 2017",23.20,23.24,18.69,19.05,"269,653","28,383,800" 118 | "Jul 14, 2017",26.80,27.67,21.18,23.24,"424,550","32,787,700" 119 | "Jul 13, 2017",30.83,31.24,25.64,26.82,"453,602","37,715,200" 120 | "Jul 12, 2017",20.32,32.90,18.75,30.71,"1,538,890","24,856,500" 121 | "Jul 11, 2017",23.53,26.49,18.33,20.73,"613,446","28,787,300" 122 | "Jul 10, 2017",28.65,31.54,20.99,24.04,"678,731","35,055,400" 123 | "Jul 09, 2017",27.54,30.14,26.83,28.29,"576,144","33,695,700" 124 | "Jul 08, 2017",28.99,30.77,23.66,27.51,"860,141","35,465,600" 125 | "Jul 07, 2017",36.08,36.88,25.44,29.39,"1,277,090","44,138,900" 126 | "Jul 06, 2017",38.60,39.21,32.20,35.79,"1,538,390","47,227,600" 127 | "Jul 05, 2017",39.39,41.59,37.64,39.03,"829,545","48,195,200" 128 | "Jul 04, 2017",41.60,43.46,37.38,39.42,"1,917,540","50,895,200" 129 | "Jul 03, 2017",43.17,46.92,41.41,41.69,"1,348,590","52,810,600" 130 | "Jul 02, 2017",43.12,54.01,39.95,42.87,"3,610,660","52,749,500" 131 | "Jul 01, 2017",34.19,68.93,33.29,45.26,"12,854,500","41,835,200" 132 | "Jun 30, 2017",42.26,43.96,29.13,34.20,"4,824,820","51,703,800" 133 | "Jun 29, 2017",53.26,53.26,38.82,42.89,"3,130,230","65,159,400" 134 | "Jun 28, 2017",51.92,58.38,46.21,53.07,"4,397,750","63,517,500" 135 | "Jun 27, 2017",59.82,62.31,36.29,53.05,"6,824,330","73,191,200" 136 | "Jun 26, 2017",88.17,98.78,49.70,59.90,"9,639,820","107,875,000" 137 | "Jun 25, 2017",103.21,168.49,72.49,86.55,"34,331,400","126,269,000" 138 | "Jun 24, 2017",44.48,116.40,42.04,101.83,"17,322,100","54,422,400" 139 | "Jun 23, 2017",35.05,48.58,17.67,45.63,"4,354,180",- 140 | -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/omisego_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",6.52,6.67,6.16,6.33,"17,428,900","665,398,000" 3 | "Nov 06, 2017",6.28,6.68,6.22,6.48,"21,223,900","617,414,000" 4 | "Nov 05, 2017",6.44,6.49,6.17,6.29,"12,819,400","633,214,000" 5 | "Nov 04, 2017",6.72,6.77,6.38,6.45,"16,963,100","660,838,000" 6 | "Nov 03, 2017",6.23,6.78,6.15,6.73,"27,548,300","612,383,000" 7 | "Nov 02, 2017",6.05,6.67,5.55,6.23,"55,264,500","594,839,000" 8 | "Nov 01, 2017",6.83,6.96,6.05,6.05,"37,953,700","671,068,000" 9 | "Oct 31, 2017",7.23,7.29,6.84,6.84,"21,797,300","710,488,000" 10 | "Oct 30, 2017",7.28,7.40,7.13,7.25,"14,224,900","715,973,000" 11 | "Oct 29, 2017",7.16,7.44,7.15,7.30,"18,076,000","703,486,000" 12 | "Oct 28, 2017",7.49,7.54,7.17,7.18,"17,242,600","736,331,000" 13 | "Oct 27, 2017",7.65,8.12,7.42,7.46,"28,704,900","751,745,000" 14 | "Oct 26, 2017",7.66,7.80,7.48,7.65,"19,134,300","752,636,000" 15 | "Oct 25, 2017",8.12,8.14,7.56,7.62,"20,363,000","798,130,000" 16 | "Oct 24, 2017",7.59,8.70,7.38,8.13,"54,151,300","746,181,000" 17 | "Oct 23, 2017",7.65,7.66,7.12,7.61,"17,684,200","752,139,000" 18 | "Oct 22, 2017",7.37,7.78,7.36,7.67,"19,588,000","724,177,000" 19 | "Oct 21, 2017",7.31,7.46,6.99,7.37,"19,448,800","718,401,000" 20 | "Oct 20, 2017",7.90,7.91,7.29,7.31,"20,554,400","776,825,000" 21 | "Oct 19, 2017",7.82,8.08,7.68,7.92,"14,064,200","769,045,000" 22 | "Oct 18, 2017",7.97,8.08,7.66,7.84,"20,915,200","783,502,000" 23 | "Oct 17, 2017",7.86,8.24,7.69,7.99,"23,177,500","772,486,000" 24 | "Oct 16, 2017",8.00,8.10,7.60,7.85,"19,951,300","786,681,000" 25 | "Oct 15, 2017",8.03,8.24,7.67,7.97,"23,508,300","789,379,000" 26 | "Oct 14, 2017",8.31,8.38,7.99,8.03,"20,284,600","816,802,000" 27 | "Oct 13, 2017",8.19,8.68,7.98,8.30,"33,908,900","805,549,000" 28 | "Oct 12, 2017",9.26,9.53,8.18,8.20,"49,996,900","910,544,000" 29 | "Oct 11, 2017",8.12,9.42,8.12,9.26,"57,741,200","798,713,000" 30 | "Oct 10, 2017",7.49,8.39,7.28,8.09,"27,542,200","736,231,000" 31 | "Oct 09, 2017",7.78,8.10,7.03,7.50,"34,823,600","765,067,000" 32 | "Oct 08, 2017",8.54,8.61,7.62,7.70,"27,120,900","839,543,000" 33 | "Oct 07, 2017",8.66,8.69,8.14,8.54,"18,207,700","851,803,000" 34 | "Oct 06, 2017",8.82,8.89,8.49,8.66,"13,957,500","866,972,000" 35 | "Oct 05, 2017",8.67,8.97,8.23,8.80,"19,715,100","852,239,000" 36 | "Oct 04, 2017",9.26,9.27,8.60,8.66,"19,933,100","909,963,000" 37 | "Oct 03, 2017",9.19,9.27,8.53,9.24,"35,595,500","903,903,000" 38 | "Oct 02, 2017",9.82,9.99,9.07,9.20,"36,673,900","965,225,000" 39 | "Oct 01, 2017",10.11,10.15,9.57,9.82,"21,494,500","994,233,000" 40 | "Sep 30, 2017",9.74,10.27,9.68,10.12,"26,871,400","957,899,000" 41 | "Sep 29, 2017",10.47,10.58,9.19,9.75,"51,306,900","1,029,050,000" 42 | "Sep 28, 2017",10.35,11.48,10.07,10.49,"66,693,200","1,017,090,000" 43 | "Sep 27, 2017",9.78,10.52,9.77,10.34,"38,915,800","961,863,000" 44 | "Sep 26, 2017",10.01,10.27,9.69,9.76,"26,920,700","984,356,000" 45 | "Sep 25, 2017",8.66,10.38,8.63,10.00,"59,857,600","851,863,000" 46 | "Sep 24, 2017",9.01,9.12,8.53,8.66,"19,730,500","885,388,000" 47 | "Sep 23, 2017",8.66,9.36,8.43,9.03,"28,436,100","851,587,000" 48 | "Sep 22, 2017",8.13,8.96,7.93,8.65,"42,277,500","799,239,000" 49 | "Sep 21, 2017",9.12,9.39,7.75,8.12,"51,911,500","897,056,000" 50 | "Sep 20, 2017",9.92,9.95,9.11,9.11,"36,072,700","975,691,000" 51 | "Sep 19, 2017",11.00,11.03,9.68,9.92,"38,392,200","1,081,420,000" 52 | "Sep 18, 2017",9.88,11.34,9.88,10.98,"54,086,300","971,499,000" 53 | "Sep 17, 2017",9.90,10.31,8.98,9.87,"40,154,600","973,696,000" 54 | "Sep 16, 2017",9.96,10.65,9.34,9.93,"66,155,100","979,204,000" 55 | "Sep 15, 2017",8.13,10.39,6.57,9.95,"156,528,000","798,813,000" 56 | "Sep 14, 2017",10.58,11.06,7.67,8.08,"95,558,500","1,040,220,000" 57 | "Sep 13, 2017",11.68,11.70,9.55,10.61,"85,896,500","1,148,450,000" 58 | "Sep 12, 2017",11.37,13.45,11.21,11.59,"130,591,000","1,117,370,000" 59 | "Sep 11, 2017",11.42,11.98,11.09,11.33,"37,733,800","1,122,960,000" 60 | "Sep 10, 2017",12.29,12.29,10.76,11.40,"53,265,800","1,207,860,000" 61 | "Sep 09, 2017",11.38,12.22,10.88,12.22,"63,245,300","1,118,990,000" 62 | "Sep 08, 2017",12.91,13.39,10.66,11.45,"99,091,800","1,268,790,000" 63 | "Sep 07, 2017",11.65,13.53,10.77,12.87,"153,192,000","1,145,440,000" 64 | "Sep 06, 2017",10.96,11.79,10.49,11.64,"95,001,000","1,077,300,000" 65 | "Sep 05, 2017",8.68,11.28,7.60,10.98,"111,430,000","852,870,000" 66 | "Sep 04, 2017",10.55,10.55,7.31,8.78,"159,979,000","1,037,440,000" 67 | "Sep 03, 2017",10.79,11.37,9.64,10.57,"68,616,800","1,060,760,000" 68 | "Sep 02, 2017",11.99,11.99,9.96,10.80,"93,561,000","1,178,610,000" 69 | "Sep 01, 2017",11.73,12.52,11.63,11.97,"91,962,400","1,153,390,000" 70 | "Aug 31, 2017",11.17,12.08,10.78,11.74,"89,710,200","1,098,470,000" 71 | "Aug 30, 2017",9.49,11.67,9.30,11.07,"194,613,000","932,958,000" 72 | "Aug 29, 2017",8.58,9.62,8.45,9.46,"86,155,000","843,249,000" 73 | "Aug 28, 2017",8.33,8.93,8.15,8.59,"52,390,300","819,005,000" 74 | "Aug 27, 2017",8.29,8.37,8.03,8.33,"22,915,000","815,412,000" 75 | "Aug 26, 2017",8.26,8.33,7.85,8.28,"25,661,900","812,289,000" 76 | "Aug 25, 2017",8.38,8.46,8.04,8.27,"24,205,300","823,620,000" 77 | "Aug 24, 2017",8.20,8.39,7.97,8.37,"31,284,200","806,267,000" 78 | "Aug 23, 2017",7.61,8.66,7.58,8.24,"64,455,600","748,515,000" 79 | "Aug 22, 2017",7.67,7.76,6.96,7.62,"41,423,400","753,880,000" 80 | "Aug 21, 2017",8.45,8.60,7.34,7.67,"71,569,400","830,536,000" 81 | "Aug 20, 2017",7.76,8.84,7.17,8.44,"74,687,700","762,542,000" 82 | "Aug 19, 2017",7.31,7.93,6.42,7.80,"70,997,400","718,510,000" 83 | "Aug 18, 2017",8.40,8.45,6.32,7.34,"104,224,000","825,591,000" 84 | "Aug 17, 2017",8.89,9.47,8.29,8.40,"131,488,000","873,548,000" 85 | "Aug 16, 2017",6.67,9.02,6.67,8.87,"204,580,000","655,537,000" 86 | "Aug 15, 2017",6.94,7.05,6.16,6.69,"67,045,700","682,506,000" 87 | "Aug 14, 2017",6.88,7.38,6.25,7.02,"85,191,300","676,804,000" 88 | "Aug 13, 2017",6.18,7.53,5.36,6.94,"128,909,000","607,772,000" 89 | "Aug 12, 2017",7.20,7.40,5.83,6.19,"87,590,300","707,779,000" 90 | "Aug 11, 2017",5.96,7.81,5.41,7.23,"200,287,000","586,021,000" 91 | "Aug 10, 2017",3.41,6.36,3.38,5.93,"234,693,000","335,183,000" 92 | "Aug 09, 2017",3.62,3.68,3.26,3.45,"24,783,900","355,440,000" 93 | "Aug 08, 2017",3.15,3.76,3.07,3.61,"49,778,700","309,766,000" 94 | "Aug 07, 2017",2.70,3.25,2.63,3.15,"34,417,900","265,138,000" 95 | "Aug 06, 2017",3.62,3.62,2.59,2.75,"39,669,900","356,183,000" 96 | "Aug 05, 2017",2.79,3.73,2.74,3.61,"95,593,700","274,109,000" 97 | "Aug 04, 2017",1.95,2.79,1.94,2.76,"44,051,500","192,003,000" 98 | "Aug 03, 2017",1.38,2.03,1.37,1.96,"18,348,800","135,528,000" 99 | "Aug 02, 2017",1.34,1.39,1.29,1.38,"3,708,080","131,707,000" 100 | "Aug 01, 2017",1.22,1.37,1.18,1.33,"4,360,060","120,415,000" 101 | "Jul 31, 2017",1.20,1.26,1.17,1.23,"2,153,100","118,309,000" 102 | "Jul 30, 2017",1.27,1.31,1.19,1.21,"1,749,290","124,645,000" 103 | "Jul 29, 2017",1.19,1.29,1.11,1.28,"2,651,230","116,968,000" 104 | "Jul 28, 2017",1.38,1.39,1.12,1.19,"5,438,700","135,475,000" 105 | "Jul 27, 2017",1.21,1.41,1.20,1.38,"5,379,280","118,718,000" 106 | "Jul 26, 2017",1.23,1.29,1.10,1.21,"4,740,910","121,110,000" 107 | "Jul 25, 2017",1.53,1.55,1.12,1.23,"8,132,390","150,667,000" 108 | "Jul 24, 2017",1.51,1.61,1.31,1.52,"12,526,000","148,581,000" 109 | "Jul 23, 2017",0.878973,1.59,0.850754,1.53,"15,198,100","86,413,600" 110 | "Jul 22, 2017",0.742038,0.886832,0.739422,0.878662,"3,596,130","72,951,200" 111 | "Jul 21, 2017",0.669754,0.786582,0.632858,0.753032,"2,140,420","65,844,800" 112 | "Jul 20, 2017",0.596119,0.717632,0.596119,0.659447,"3,376,440","58,605,700" 113 | "Jul 19, 2017",0.759290,0.797288,0.568905,0.583911,"4,236,020","74,647,300" 114 | "Jul 18, 2017",0.574224,0.894874,0.565539,0.759819,"8,394,650","56,453,100" 115 | "Jul 17, 2017",0.381684,0.598633,0.379345,0.582786,"4,273,090","37,524,100" 116 | "Jul 16, 2017",0.431081,0.494342,0.319695,0.384906,"1,743,630","42,380,400" 117 | "Jul 15, 2017",0.586446,0.652156,0.433351,0.433351,"1,552,730",- 118 | "Jul 14, 2017",0.534731,0.775406,0.500232,0.582480,"750,698",- 119 | -------------------------------------------------------------------------------- /v2/cryptocurrencypricehistory/qtum_price.csv: -------------------------------------------------------------------------------- 1 | Date,Open,High,Low,Close,Volume,Market Cap 2 | "Nov 07, 2017",10.32,11.45,10.32,11.21,"122,951,000","760,320,000" 3 | "Nov 06, 2017",10.13,11.18,10.06,10.44,"116,937,000","745,802,000" 4 | "Nov 05, 2017",10.04,10.43,9.96,10.13,"49,288,500","739,113,000" 5 | "Nov 04, 2017",10.31,10.40,9.82,10.05,"35,477,100","759,110,000" 6 | "Nov 03, 2017",9.77,10.42,9.70,10.38,"55,018,600","719,701,000" 7 | "Nov 02, 2017",9.95,10.04,9.35,9.80,"54,501,600","732,691,000" 8 | "Nov 01, 2017",10.41,10.41,9.92,9.93,"26,591,700","766,698,000" 9 | "Oct 31, 2017",10.38,10.88,10.35,10.45,"43,306,600","764,029,000" 10 | "Oct 30, 2017",10.39,10.48,10.29,10.39,"21,781,900","765,031,000" 11 | "Oct 29, 2017",10.19,10.54,10.18,10.42,"40,119,600","750,443,000" 12 | "Oct 28, 2017",10.33,10.38,10.18,10.21,"23,588,200","760,135,000" 13 | "Oct 27, 2017",10.56,10.63,10.26,10.30,"27,344,700","777,594,000" 14 | "Oct 26, 2017",10.66,10.79,10.45,10.57,"26,461,700","784,784,000" 15 | "Oct 25, 2017",10.78,10.92,10.37,10.65,"48,104,100","793,779,000" 16 | "Oct 24, 2017",9.96,11.46,9.52,10.76,"118,813,000","733,399,000" 17 | "Oct 23, 2017",10.59,10.60,9.75,9.96,"50,654,800","779,244,000" 18 | "Oct 22, 2017",10.97,11.06,10.56,10.63,"33,890,300","807,214,000" 19 | "Oct 21, 2017",11.25,11.35,10.50,10.91,"56,075,000","828,306,000" 20 | "Oct 20, 2017",12.10,15.12,11.19,11.30,"304,281,000","890,682,000" 21 | "Oct 19, 2017",11.46,12.22,11.35,12.07,"49,308,300","688,986,000" 22 | "Oct 18, 2017",12.04,12.04,10.78,11.49,"53,960,300","710,326,000" 23 | "Oct 17, 2017",11.48,12.27,11.03,12.05,"57,046,400","677,311,000" 24 | "Oct 16, 2017",10.46,11.65,10.23,11.49,"37,568,400","616,895,000" 25 | "Oct 15, 2017",10.64,10.66,10.09,10.44,"22,057,700","627,948,000" 26 | "Oct 14, 2017",11.26,11.45,10.62,10.63,"17,709,400","664,129,000" 27 | "Oct 13, 2017",11.30,11.30,10.31,11.25,"44,760,500","666,714,000" 28 | "Oct 12, 2017",12.13,12.21,11.29,11.29,"31,335,300","715,782,000" 29 | "Oct 11, 2017",12.04,12.29,11.87,12.13,"28,771,600","710,230,000" 30 | "Oct 10, 2017",12.04,12.54,11.55,12.08,"50,232,800","710,536,000" 31 | "Oct 09, 2017",11.14,12.49,10.96,12.07,"57,974,000","657,304,000" 32 | "Oct 08, 2017",11.96,12.11,11.14,11.14,"34,305,900","705,791,000" 33 | "Oct 07, 2017",11.67,11.94,11.51,11.94,"19,498,800","688,284,000" 34 | "Oct 06, 2017",11.87,11.91,11.50,11.69,"23,341,500","700,544,000" 35 | "Oct 05, 2017",11.60,11.98,10.82,11.86,"67,610,800","684,358,000" 36 | "Oct 04, 2017",12.16,12.28,11.51,11.63,"77,387,000","717,223,000" 37 | "Oct 03, 2017",11.91,12.12,10.78,12.12,"95,756,400","702,872,000" 38 | "Oct 02, 2017",12.36,12.38,11.43,11.88,"69,789,000","729,062,000" 39 | "Oct 01, 2017",11.59,12.61,11.58,12.34,"162,762,000","683,566,000" 40 | "Sep 30, 2017",9.77,11.65,9.75,11.59,"141,320,000","576,371,000" 41 | "Sep 29, 2017",9.96,10.00,9.15,9.77,"79,526,300","587,845,000" 42 | "Sep 28, 2017",9.95,10.10,9.06,9.93,"95,333,300","586,983,000" 43 | "Sep 27, 2017",9.37,9.90,9.35,9.90,"59,847,700","552,811,000" 44 | "Sep 26, 2017",9.38,10.30,9.17,9.34,"104,988,000","553,598,000" 45 | "Sep 25, 2017",8.03,9.60,8.03,9.36,"82,385,100","473,818,000" 46 | "Sep 24, 2017",8.10,8.28,7.79,8.04,"28,266,800","477,945,000" 47 | "Sep 23, 2017",7.70,8.21,7.48,8.11,"40,760,800","454,162,000" 48 | "Sep 22, 2017",7.34,7.91,7.27,7.68,"42,861,600","433,000,000" 49 | "Sep 21, 2017",8.77,8.81,7.34,7.38,"38,239,000","517,612,000" 50 | "Sep 20, 2017",8.92,9.05,8.47,8.79,"38,916,900","526,414,000" 51 | "Sep 19, 2017",9.65,9.70,8.75,8.91,"66,250,600","569,633,000" 52 | "Sep 18, 2017",8.31,10.51,8.31,9.62,"167,586,000","490,417,000" 53 | "Sep 17, 2017",8.19,8.79,7.59,8.27,"69,847,200","482,927,000" 54 | "Sep 16, 2017",8.49,8.97,7.44,8.25,"97,992,200","500,809,000" 55 | "Sep 15, 2017",7.72,9.31,5.91,8.47,"242,984,000","455,212,000" 56 | "Sep 14, 2017",11.94,12.18,7.60,7.60,"137,040,000","704,415,000" 57 | "Sep 13, 2017",13.45,13.53,11.60,11.94,"185,348,000","793,825,000" 58 | "Sep 12, 2017",14.38,15.31,12.86,13.51,"156,187,000","848,364,000" 59 | "Sep 11, 2017",12.64,14.79,12.55,14.28,"165,283,000","745,787,000" 60 | "Sep 10, 2017",13.27,13.34,11.38,12.78,"172,687,000","783,150,000" 61 | "Sep 09, 2017",13.40,13.63,12.46,13.32,"99,008,100","790,322,000" 62 | "Sep 08, 2017",14.74,16.07,12.44,13.50,"294,169,000","869,878,000" 63 | "Sep 07, 2017",11.40,14.77,10.69,14.74,"195,986,000","672,888,000" 64 | "Sep 06, 2017",11.73,12.49,10.34,11.40,"141,347,000","691,921,000" 65 | "Sep 05, 2017",11.07,12.07,8.77,11.71,"218,917,000","653,177,000" 66 | "Sep 04, 2017",15.29,15.44,10.22,10.98,"161,203,000","902,407,000" 67 | "Sep 03, 2017",16.41,16.74,14.19,15.29,"98,105,400","967,971,000" 68 | "Sep 02, 2017",18.26,19.06,15.51,16.39,"123,479,000","1,077,370,000" 69 | "Sep 01, 2017",17.30,18.47,16.94,18.26,"73,618,500","1,020,980,000" 70 | "Aug 31, 2017",16.72,18.08,16.69,17.30,"76,872,500","986,295,000" 71 | "Aug 30, 2017",19.05,19.05,14.58,16.84,"145,512,000","1,124,200,000" 72 | "Aug 29, 2017",16.28,20.04,16.28,19.15,"216,784,000","960,486,000" 73 | "Aug 28, 2017",15.66,16.35,14.86,16.24,"82,850,200","923,722,000" 74 | "Aug 27, 2017",15.42,15.86,14.74,15.70,"56,474,400","909,788,000" 75 | "Aug 26, 2017",13.26,15.89,12.97,15.41,"88,172,500","782,374,000" 76 | "Aug 25, 2017",13.75,13.85,12.85,13.32,"26,327,100","811,035,000" 77 | "Aug 24, 2017",11.87,14.13,11.64,13.78,"72,955,500","700,167,000" 78 | "Aug 23, 2017",11.05,12.47,11.04,11.90,"36,722,000","651,839,000" 79 | "Aug 22, 2017",11.20,11.41,10.17,11.06,"25,086,300","660,585,000" 80 | "Aug 21, 2017",11.80,11.87,10.82,11.23,"29,380,800","696,434,000" 81 | "Aug 20, 2017",11.54,12.35,10.82,11.79,"40,638,800","680,885,000" 82 | "Aug 19, 2017",11.62,12.36,9.69,11.64,"54,327,300","685,316,000" 83 | "Aug 18, 2017",13.09,13.09,11.00,11.63,"43,226,400","772,302,000" 84 | "Aug 17, 2017",14.36,14.37,12.82,13.06,"50,489,100","847,017,000" 85 | "Aug 16, 2017",14.67,15.42,14.15,14.35,"59,126,000","865,463,000" 86 | "Aug 15, 2017",15.01,15.30,13.83,14.68,"62,353,100","885,415,000" 87 | "Aug 14, 2017",15.10,17.16,14.36,15.06,"103,750,000","890,836,000" 88 | "Aug 13, 2017",13.92,15.84,12.79,15.17,"75,650,500","821,280,000" 89 | "Aug 12, 2017",14.73,15.47,12.85,13.90,"59,321,200","868,962,000" 90 | "Aug 11, 2017",15.63,16.36,14.33,14.73,"91,215,900","922,433,000" 91 | "Aug 10, 2017",12.55,16.99,12.42,15.77,"133,259,000","740,715,000" 92 | "Aug 09, 2017",11.49,12.63,11.07,12.55,"52,016,000","677,866,000" 93 | "Aug 08, 2017",12.64,12.74,10.84,11.50,"63,155,600","746,010,000" 94 | "Aug 07, 2017",10.03,12.84,9.88,12.65,"95,630,200","591,790,000" 95 | "Aug 06, 2017",9.34,10.83,9.08,10.07,"54,977,800","550,855,000" 96 | "Aug 05, 2017",8.22,9.52,7.80,9.38,"42,482,900","484,803,000" 97 | "Aug 04, 2017",7.68,8.71,7.68,8.22,"31,879,600","452,969,000" 98 | "Aug 03, 2017",6.42,7.86,6.17,7.65,"30,278,900","378,741,000" 99 | "Aug 02, 2017",6.56,6.69,6.32,6.43,"11,978,000","387,234,000" 100 | "Aug 01, 2017",6.12,6.67,5.74,6.49,"20,864,300","361,165,000" 101 | "Jul 31, 2017",5.53,6.36,5.43,6.12,"13,123,400","326,029,000" 102 | "Jul 30, 2017",5.77,5.84,5.46,5.53,"3,168,030","340,554,000" 103 | "Jul 29, 2017",5.80,5.86,5.38,5.78,"5,188,990","342,217,000" 104 | "Jul 28, 2017",6.23,6.31,5.74,5.75,"7,599,310","367,403,000" 105 | "Jul 27, 2017",6.29,6.42,6.02,6.21,"10,757,800","370,867,000" 106 | "Jul 26, 2017",6.14,6.49,5.28,6.26,"20,824,500","362,203,000" 107 | "Jul 25, 2017",7.31,7.61,5.68,6.13,"22,782,500","372,639,000" 108 | "Jul 24, 2017",6.67,7.30,6.46,7.26,"12,601,300","339,927,000" 109 | "Jul 23, 2017",7.55,7.62,6.14,6.64,"23,752,700","385,277,000" 110 | "Jul 22, 2017",7.81,7.99,7.48,7.52,"16,650,500","398,441,000" 111 | "Jul 21, 2017",7.84,9.15,7.01,7.84,"48,210,600","399,824,000" 112 | "Jul 20, 2017",5.69,7.68,5.69,7.59,"33,148,900","289,993,000" 113 | "Jul 19, 2017",5.18,6.62,4.79,5.62,"29,526,300","264,087,000" 114 | "Jul 18, 2017",4.41,5.35,4.27,5.18,"16,788,400","224,792,000" 115 | "Jul 17, 2017",3.91,4.47,3.91,4.38,"7,531,300","199,276,000" 116 | "Jul 16, 2017",3.93,4.24,3.71,3.93,"5,467,430","200,412,000" 117 | "Jul 15, 2017",4.54,4.55,3.86,3.88,"6,403,170","231,785,000" 118 | "Jul 14, 2017",5.11,5.18,4.47,4.53,"6,385,700","260,726,000" 119 | "Jul 13, 2017",5.65,6.12,5.02,5.11,"8,076,010","288,266,000" 120 | "Jul 12, 2017",4.67,5.69,4.36,5.59,"11,808,500",- 121 | "Jul 11, 2017",5.23,5.42,3.89,4.82,"11,515,200",- 122 | "Jul 10, 2017",6.42,6.75,5.03,5.38,"5,648,270",- 123 | "Jul 09, 2017",6.91,7.58,6.35,6.36,"6,985,260",- 124 | "Jul 08, 2017",6.90,7.11,5.64,6.86,"12,481,200",- 125 | "Jul 07, 2017",8.73,8.75,6.67,6.87,"7,176,910",- 126 | "Jul 06, 2017",8.44,9.35,7.95,8.75,"13,670,300",- 127 | "Jul 05, 2017",9.33,9.33,7.96,8.30,"8,151,290",- 128 | "Jul 04, 2017",9.24,9.94,8.92,9.27,"8,178,690",- 129 | "Jul 03, 2017",9.33,10.08,8.56,9.19,"15,403,500",- 130 | "Jul 02, 2017",10.41,10.41,8.18,9.45,"23,967,300",- 131 | "Jul 01, 2017",11.96,12.12,10.37,10.39,"10,832,000",- 132 | "Jun 30, 2017",12.46,12.57,11.66,12.03,"14,022,600",- 133 | "Jun 29, 2017",14.09,14.09,12.33,12.48,"18,516,000",- 134 | "Jun 28, 2017",14.68,15.68,12.97,13.83,"40,650,500",- 135 | "Jun 27, 2017",12.27,15.19,11.94,14.47,"42,563,100",- 136 | "Jun 26, 2017",14.96,14.96,10.64,12.61,"25,803,900",- 137 | "Jun 25, 2017",16.34,16.70,14.36,14.92,"22,702,400",- 138 | "Jun 24, 2017",16.80,18.85,16.02,16.35,"34,660,100",- 139 | "Jun 23, 2017",12.13,18.58,11.97,16.99,"66,737,400",- 140 | "Jun 22, 2017",11.92,12.45,11.74,12.10,"16,740,600",- 141 | "Jun 21, 2017",11.40,12.55,11.38,11.83,"10,464,200",- 142 | "Jun 20, 2017",10.57,12.88,10.44,11.49,"22,123,200",- 143 | "Jun 19, 2017",10.49,11.30,10.26,10.59,"12,893,100",- 144 | "Jun 18, 2017",11.25,11.29,10.40,10.58,"5,475,110",- 145 | "Jun 17, 2017",11.24,11.45,11.02,11.25,"6,961,310",- 146 | "Jun 16, 2017",11.11,11.73,10.69,11.29,"7,179,610",- 147 | "Jun 15, 2017",11.80,11.80,9.80,11.11,"13,740,900",- 148 | "Jun 14, 2017",12.40,13.01,11.29,11.77,"18,671,800",- 149 | "Jun 13, 2017",11.06,12.52,10.97,12.42,"16,198,200",- 150 | "Jun 12, 2017",11.77,11.82,10.87,10.96,"8,663,550",- 151 | "Jun 11, 2017",11.36,12.23,11.10,11.76,"11,384,700",- 152 | "Jun 10, 2017",11.75,12.10,11.12,11.33,"14,370,200",- 153 | "Jun 09, 2017",12.35,13.12,11.30,11.74,"14,694,100",- 154 | "Jun 08, 2017",10.92,12.54,10.26,12.35,"12,978,300",- 155 | "Jun 07, 2017",11.57,11.86,10.93,10.97,"6,104,140",- 156 | "Jun 06, 2017",10.98,12.02,10.17,11.50,"11,135,000",- 157 | "Jun 05, 2017",12.13,12.58,10.88,11.17,"10,290,000",- 158 | "Jun 04, 2017",12.73,12.78,11.34,12.15,"15,253,900",- 159 | "Jun 03, 2017",13.17,13.70,11.39,12.54,"39,565,100",- 160 | "Jun 02, 2017",7.86,13.60,7.86,13.46,"54,232,400",- 161 | "Jun 01, 2017",4.86,8.37,4.78,7.79,"28,193,200",- 162 | "May 31, 2017",4.61,4.88,4.50,4.86,"3,011,070",- 163 | "May 30, 2017",4.62,5.07,4.53,4.65,"2,836,480",- 164 | "May 29, 2017",4.64,4.88,4.36,4.60,"2,205,420",- 165 | "May 28, 2017",4.86,5.06,4.19,4.62,"4,353,380",- 166 | "May 27, 2017",4.05,4.53,3.19,4.53,"7,046,840",- 167 | "May 26, 2017",4.66,5.33,3.39,4.10,"5,116,020",- 168 | "May 25, 2017",6.19,6.29,4.57,4.66,"6,211,020",- 169 | "May 24, 2017",6.42,6.76,5.68,6.19,"11,221,600",- 170 | -------------------------------------------------------------------------------- /v2/ddqn_agent.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "code", 5 | "execution_count": null, 6 | "metadata": { 7 | "collapsed": true 8 | }, 9 | "outputs": [], 10 | "source": [ 11 | "\n", 12 | "'''\n", 13 | "\n", 14 | "### Cryptocurrency Trader Agent\n", 15 | "### UCB MIDS 2017 Winter Capstone Project\n", 16 | "### Ramsey Aweti, Shuang Chan, GuangZhi(Frank) Xie, Jason Xie\n", 17 | "\n", 18 | "### Class: \n", 19 | "### DDQNAgent\n", 20 | "### Purpose: \n", 21 | "### Deep Q Learning Implementation\n", 22 | "### Sample Usage:\n", 23 | "\n", 24 | "# trader = DDQNAgent()\n", 25 | "# trader.train(50)\n", 26 | "# trader.test()\n", 27 | "\n", 28 | "'''\n", 29 | "\n", 30 | "from env import *\n", 31 | "from portfolio import *\n", 32 | "\n", 33 | "from keras.models import Sequential\n", 34 | "from keras.layers import Dense\n", 35 | "from keras.optimizers import Adam\n", 36 | "from keras import backend as K\n", 37 | "from keras.models import load_model\n", 38 | "\n", 39 | "# Neural Network for the Q value approximation\n", 40 | "class QValue_NN:\n", 41 | " def __init__(self, state_size, action_size, units):\n", 42 | " self._state_size = state_size\n", 43 | " self._action_size = action_size\n", 44 | " self._units = units\n", 45 | " self._model = self.__build_model()\n", 46 | " \n", 47 | " def __huber_loss(self, target, prediction):\n", 48 | " # sqrt(1+error^2)-1\n", 49 | " error = prediction - target\n", 50 | " return K.mean(K.sqrt(1+K.square(error))-1, axis=-1)\n", 51 | "\n", 52 | " def __build_model(self):\n", 53 | " model = Sequential()\n", 54 | " model.add(Dense(self._units, input_dim=self._state_size, activation='relu'))\n", 55 | " model.add(Dense(self._units, activation='relu'))\n", 56 | " model.add(Dense(self._action_size, activation='linear'))\n", 57 | " model.compile(loss=self.__huber_loss, optimizer='adam')\n", 58 | " return model\n", 59 | "\n", 60 | " def train(self, state, qvalues):\n", 61 | " state_reshape = np.reshape(state, [1, len(state)])\n", 62 | " self._model.fit(state_reshape, qvalues, epochs=1, verbose=0)\n", 63 | "\n", 64 | " def predict(self, state):\n", 65 | " state_reshape = np.reshape(state, [1, len(state)])\n", 66 | " return self._model.predict(state_reshape)\n", 67 | " \n", 68 | " def set_weights(self, model_weights):\n", 69 | " self._model.set_weights(model_weights)\n", 70 | " \n", 71 | " def get_weights(self):\n", 72 | " return self._model.get_weights()\n", 73 | " \n", 74 | " def save(self, path):\n", 75 | " self._model.save_weights(path)\n", 76 | " \n", 77 | " def load(self, path):\n", 78 | " self._model.load_weights(path)\n", 79 | " \n", 80 | "\n", 81 | "import random\n", 82 | "import numpy as np\n", 83 | "from collections import deque\n", 84 | "\n", 85 | "# Agent Implementation\n", 86 | "\n", 87 | "class DDQNAgent:\n", 88 | " \n", 89 | " # initialize internal variables\n", 90 | " def __init__(self, gamma=0.95, num_neutron=24, epsilon_min = 0.001, epsilon_decay=0.99, \n", 91 | " init_capital=1000, coin_name='ethereum', num_coins_per_order=100, recent_k = 0,\n", 92 | " external_states = [\"current_price\", \"rolling_mean\", \"rolling_std\", \n", 93 | " \"cross_upper_band\", \"cross_lower_band\"],\n", 94 | " internal_states = [\"coin\", \"cash\", \"total_value\"]):\n", 95 | " self.memory = deque(maxlen=2000)\n", 96 | " self.batch_size = 32\n", 97 | " self.gamma = gamma\n", 98 | " self.epsilon=1.0\n", 99 | " self.epsilon_min=epsilon_min \n", 100 | " self.epsilon_decay=epsilon_decay\n", 101 | " self.coin_name = coin_name\n", 102 | " # External states\n", 103 | " self.external_states = external_states\n", 104 | " self.env = Environment(coin_name=coin_name, states=external_states, recent_k=recent_k)\n", 105 | " # Internal states\n", 106 | " self.internal_states = internal_states\n", 107 | " self.portfolio = Portfolio(portfolio_cash=init_capital, num_coins_per_order=num_coins_per_order, states=internal_states)\n", 108 | " # NN model\n", 109 | " _state_size = self.env.getStateSpaceSize() + self.portfolio.getStateSpaceSize()\n", 110 | " self.model = QValue_NN(_state_size, self.portfolio.getActionSpaceSize(), num_neutron)\n", 111 | " self.target_model = QValue_NN(_state_size, self.portfolio.getActionSpaceSize(), num_neutron)\n", 112 | " \n", 113 | " self.cum_returns = []\n", 114 | " \n", 115 | " def plot_external_states(self):\n", 116 | " self.env.plot(self.external_states)\n", 117 | " \n", 118 | " \n", 119 | " def __act(self, state):\n", 120 | " if np.random.rand() < self.epsilon:\n", 121 | " return random.choice(list(Action))\n", 122 | " act_values = self.model.predict(state)\n", 123 | " return Action(np.argmax(act_values[0]))\n", 124 | " \n", 125 | " def __remember(self, state, action, reward, next_state, isDone):\n", 126 | " self.memory.append((state, action, reward, next_state, isDone))\n", 127 | " \n", 128 | " def __update_target_model(self):\n", 129 | " self.target_model._model.set_weights(self.model._model.get_weights())\n", 130 | "\n", 131 | " def print_my_memory(self):\n", 132 | " mem = list(self.memory)\n", 133 | " mem_str = []\n", 134 | " for s, a, r, s_, donzo in mem:\n", 135 | " mem_str += [\"%s_%s_%s_%s_%s\" % (str(s), str(a), str(r), str(s_), str(donzo))]\n", 136 | " \n", 137 | " uniques = list(set(mem_str))\n", 138 | " uniques.sort() \n", 139 | " \n", 140 | " for elem in uniques:\n", 141 | " print elem\n", 142 | " print mem_str.count(elem)\n", 143 | " print \"\\n\"\n", 144 | " \n", 145 | " def __replay(self, batch_size):\n", 146 | " minibatch = random.sample(self.memory, self.batch_size)\n", 147 | " \n", 148 | " for state, action, reward, next_state, isDone in minibatch:\n", 149 | " target = self.model.predict(state)\n", 150 | " if isDone:\n", 151 | " target[0][action.value] = reward\n", 152 | " else:\n", 153 | " a = self.model.predict(next_state)[0]\n", 154 | " t = self.target_model.predict(next_state)[0]\n", 155 | " \n", 156 | " # Bellman Equation\n", 157 | " # -0.60 + gamma * -0.50\n", 158 | " target[0][action.value] = reward + self.gamma * t[np.argmax(a)]\n", 159 | "\n", 160 | " self.model.train(state, target)\n", 161 | " \n", 162 | " # update the epsilon to gradually reduce the random exploration\n", 163 | " if self.epsilon > self.epsilon_min:\n", 164 | " self.epsilon *= self.epsilon_decay\n", 165 | "\n", 166 | " # Agent Training\n", 167 | " def train(self, num_episodes=100):\n", 168 | " self.cum_returns = []\n", 169 | " \n", 170 | " for i in range(num_episodes):\n", 171 | " \n", 172 | " self.env.reset()\n", 173 | " self.portfolio.reset()\n", 174 | " state = self.env.getStates() + self.portfolio.getStates()\n", 175 | "\n", 176 | " # walk through the environment\n", 177 | " # obtain action based on state values using the Neural Network model\n", 178 | " # collect reward\n", 179 | " # update the experience in Memory\n", 180 | " while (True):\n", 181 | " action = self.__act(state)\n", 182 | " self.portfolio.apply_action(self.env.getCurrentPrice(), action)\n", 183 | " \n", 184 | " isDone, next_state = self.env.step()\n", 185 | " next_state = next_state + self.portfolio.getStates()\n", 186 | " reward = self.portfolio.getReward()\n", 187 | " \n", 188 | " self.__remember(state, action, reward, next_state, isDone)\n", 189 | " state = next_state\n", 190 | " \n", 191 | " if isDone:\n", 192 | " self.__update_target_model()\n", 193 | " \n", 194 | " cum_return = self.portfolio.getReturnsPercent(self.env.getCurrentPrice())\n", 195 | " self.cum_returns.append(cum_return)\n", 196 | " \n", 197 | " print(\"episode: {}/{}, returns: {}, epsilon: {:.2}\"\n", 198 | " .format(i+1, num_episodes, \n", 199 | " cum_return, \n", 200 | " self.epsilon))\n", 201 | " break\n", 202 | " \n", 203 | " # train the Neural Network incrementally with the new experiences\n", 204 | " if len(self.memory) > self.batch_size:\n", 205 | " self.__replay(self.batch_size)\n", 206 | " \n", 207 | " self.target_model.save('model/{}.model.h5'.format(self.coin_name))\n", 208 | " \n", 209 | " \n", 210 | " def test(self, epsilon = None):\n", 211 | " if epsilon is None:\n", 212 | " epsilon = self.epsilon\n", 213 | " \n", 214 | " self.env.reset()\n", 215 | " self.portfolio.reset()\n", 216 | " state = self.env.getStates() + self.portfolio.getStates()\n", 217 | " self.model.load('model/{}.model.h5'.format(self.coin_name))\n", 218 | "\n", 219 | " while (True):\n", 220 | " action = self.__act(state)\n", 221 | " print action\n", 222 | " self.portfolio.apply_action(state[0], action)\n", 223 | " \n", 224 | " isDone, next_state = self.env.step()\n", 225 | " next_state = next_state + self.portfolio.getStates()\n", 226 | " reward = self.portfolio.getReward()\n", 227 | " state = next_state\n", 228 | " \n", 229 | " if isDone:\n", 230 | " \tbreak\n", 231 | "\n", 232 | " print self.portfolio.getReturnsPercent(self.env.getCurrentPrice())\n", 233 | " \n", 234 | " \n", 235 | " def plot_cum_returns(self):\n", 236 | " import matplotlib.pyplot as plt\n", 237 | " \n", 238 | " plt.figure(figsize=(10,6))\n", 239 | " x = [i for i in range(len(self.cum_returns))]\n", 240 | " plt.plot(x, self.cum_returns)\n", 241 | " plt.show()\n" 242 | ] 243 | } 244 | ], 245 | "metadata": { 246 | "kernelspec": { 247 | "display_name": "Python 2", 248 | "language": "python", 249 | "name": "python2" 250 | }, 251 | "language_info": { 252 | "codemirror_mode": { 253 | "name": "ipython", 254 | "version": 2 255 | }, 256 | "file_extension": ".py", 257 | "mimetype": "text/x-python", 258 | "name": "python", 259 | "nbconvert_exporter": "python", 260 | "pygments_lexer": "ipython2", 261 | "version": "2.7.11" 262 | } 263 | }, 264 | "nbformat": 4, 265 | "nbformat_minor": 2 266 | } 267 | -------------------------------------------------------------------------------- /v2/ddqn_agent.py: -------------------------------------------------------------------------------- 1 | 2 | ''' 3 | 4 | ### Cryptocurrency Trader Agent 5 | ### UCB MIDS 2017 Winter Capstone Project 6 | ### Ramsey Aweti, Shuang Chan, GuangZhi(Frank) Xie, Jason Xie 7 | 8 | ### Class: 9 | ### DDQNAgent 10 | ### Purpose: 11 | ### Deep Q Learning Implementation 12 | ### Sample Usage: 13 | 14 | # trader = DDQNAgent() 15 | # trader.train(50) 16 | # trader.test() 17 | 18 | ''' 19 | 20 | from env import * 21 | from portfolio import * 22 | 23 | from keras.models import Sequential 24 | from keras.layers import Dense 25 | from keras.optimizers import Adam 26 | from keras import backend as K 27 | from keras import initializers 28 | from keras.models import load_model 29 | 30 | # Neural Network for the Q value approximation 31 | class QValue_NN: 32 | def __init__(self, state_size, action_size, units): 33 | self._state_size = state_size 34 | self._action_size = action_size 35 | self._units = units 36 | self._model = self.__build_model() 37 | 38 | def __huber_loss(self, target, prediction): 39 | # sqrt(1+error^2)-1 40 | error = prediction - target 41 | return K.mean(K.sqrt(1+K.square(error))-1, axis=-1) 42 | 43 | def __build_model(self): 44 | model = Sequential() 45 | model.add(Dense(self._units, input_dim=self._state_size, activation='relu', 46 | kernel_initializer=initializers.RandomNormal(stddev=0.001, seed=3456), 47 | bias_initializer='zeros')) 48 | model.add(Dense(self._units, activation='relu', 49 | kernel_initializer=initializers.RandomNormal(stddev=0.001, seed=3456), 50 | bias_initializer='zeros')) 51 | model.add(Dense(self._action_size, activation='linear', 52 | kernel_initializer=initializers.RandomNormal(stddev=0.001, seed=3456), 53 | bias_initializer='zeros')) 54 | model.compile(loss=self.__huber_loss, optimizer="adam") 55 | return model 56 | 57 | def train(self, state, qvalues): 58 | state_reshape = np.reshape(state, [1, len(state)]) 59 | self._model.fit(state_reshape, qvalues, epochs=1, verbose=0) 60 | 61 | def predict(self, state): 62 | state_reshape = np.reshape(state, [1, len(state)]) 63 | return self._model.predict(state_reshape) 64 | 65 | def set_weights(self, model_weights): 66 | self._model.set_weights(model_weights) 67 | 68 | def get_weights(self): 69 | return self._model.get_weights() 70 | 71 | def save(self, path): 72 | self._model.save_weights(path) 73 | 74 | def load(self, path): 75 | self._model.load_weights(path) 76 | 77 | 78 | import random 79 | import numpy as np 80 | from collections import deque 81 | 82 | # Agent Implementation 83 | 84 | class DDQNAgent: 85 | 86 | # initialize internal variables 87 | def __init__(self, gamma=0.95, num_neutron=24, epsilon_min = 0.001, epsilon_decay=0.995, 88 | coin_name='ethereum', num_coins_per_order=100, recent_k = 0, 89 | external_states = ["current_price", "rolling_mean", "rolling_std", 90 | "cross_upper_band", "cross_lower_band"], 91 | internal_states = ["coin", "cash", "total_value"], verbose=False): 92 | self.memory = deque(maxlen=2000) 93 | self.batch_size = 32 94 | self.gamma = gamma 95 | self.epsilon=1.0 96 | self.epsilon_min=epsilon_min 97 | self.epsilon_decay=epsilon_decay 98 | self.coin_name = coin_name 99 | # External states 100 | self.external_states = external_states 101 | self.env = Environment(coin_name=coin_name, states=external_states, recent_k=recent_k) 102 | # Internal states 103 | self.internal_states = internal_states 104 | self.portfolio = Portfolio(num_coins_per_order=num_coins_per_order, states=internal_states, 105 | verbose=verbose, final_price=self.env.getFinalPrice()) 106 | # NN model 107 | _state_size = self.env.getStateSpaceSize() + self.portfolio.getStateSpaceSize() 108 | self.model = QValue_NN(_state_size, self.portfolio.getActionSpaceSize(), num_neutron) 109 | self.target_model = QValue_NN(_state_size, self.portfolio.getActionSpaceSize(), num_neutron) 110 | 111 | self.cum_returns = [] 112 | 113 | def plot_external_states(self): 114 | self.env.plot(self.external_states) 115 | 116 | 117 | def __act(self, state): 118 | if np.random.rand() < self.epsilon: 119 | return random.choice(list(Action)) 120 | act_values = self.model.predict(state) 121 | return Action(np.argmax(act_values[0])) 122 | 123 | def __remember(self, state, action, reward, next_state, isDone): 124 | self.memory.append((state, action, reward, next_state, isDone)) 125 | 126 | def __update_target_model(self): 127 | self.target_model._model.set_weights(self.model._model.get_weights()) 128 | 129 | def print_my_memory(self): 130 | mem = list(self.memory) 131 | mem_str = [] 132 | for s, a, r, s_, donzo in mem: 133 | mem_str += ["%s_%s_%s_%s_%s" % (str(s), str(a), str(r), str(s_), str(donzo))] 134 | 135 | uniques = list(set(mem_str)) 136 | uniques.sort() 137 | 138 | for elem in uniques: 139 | print elem 140 | print mem_str.count(elem) 141 | print "\n" 142 | 143 | def __replay(self, batch_size): 144 | minibatch = random.sample(self.memory, self.batch_size) 145 | 146 | for state, action, reward, next_state, isDone in minibatch: 147 | target = self.model.predict(state) 148 | if isDone: 149 | target[0][action.value] = reward 150 | else: 151 | a = self.model.predict(next_state)[0] 152 | t = self.target_model.predict(next_state)[0] 153 | 154 | # Bellman Equation 155 | # -0.60 + gamma * -0.50 156 | target[0][action.value] = reward + self.gamma * t[np.argmax(a)] 157 | 158 | self.model.train(state, target) 159 | 160 | # update the epsilon to gradually reduce the random exploration 161 | if self.epsilon > self.epsilon_min: 162 | self.epsilon *= self.epsilon_decay 163 | 164 | # Agent Training 165 | def train(self, num_episodes=100): 166 | self.cum_returns = [] 167 | 168 | for i in range(num_episodes): 169 | 170 | self.env.reset() 171 | self.portfolio.reset() 172 | state = self.env.getStates() + self.portfolio.getStates() 173 | 174 | # walk through the environment 175 | # obtain action based on state values using the Neural Network model 176 | # collect reward 177 | # update the experience in Memory 178 | while (True): 179 | action = self.__act(state) 180 | action = self.portfolio.apply_action(self.env.getCurrentPrice(), action) 181 | 182 | isDone, next_state = self.env.step() 183 | next_state = next_state + self.portfolio.getStates() 184 | #reward = self.portfolio.getReward() 185 | reward = self.env.getReward(action) 186 | 187 | self.__remember(state, action, reward, next_state, isDone) 188 | state = next_state 189 | 190 | if isDone: 191 | self.__update_target_model() 192 | 193 | cum_return = self.portfolio.getReturnsPercent(self.env.getCurrentPrice()) 194 | self.cum_returns.append(cum_return) 195 | 196 | print("episode: {}/{}, returns: {}, epsilon: {:.2}" 197 | .format(i+1, num_episodes, 198 | cum_return, 199 | self.epsilon)) 200 | break 201 | 202 | # train the Neural Network incrementally with the new experiences 203 | if len(self.memory) > self.batch_size: 204 | self.__replay(self.batch_size) 205 | 206 | self.target_model.save('model/{}.model.h5'.format(self.coin_name)) 207 | 208 | 209 | def test(self, epsilon = None): 210 | if epsilon is not None: 211 | self.epsilon = epsilon 212 | 213 | self.env.reset() 214 | self.portfolio.reset() 215 | state = self.env.getStates() + self.portfolio.getStates() 216 | self.model.load('model/{}.model.h5'.format(self.coin_name)) 217 | 218 | while (True): 219 | action = self.__act(state) 220 | action = self.portfolio.apply_action(self.env.getCurrentPrice(), action) 221 | print action 222 | 223 | isDone, next_state = self.env.step() 224 | next_state = next_state + self.portfolio.getStates() 225 | state = next_state 226 | 227 | if isDone: 228 | break 229 | 230 | print self.portfolio.getReturnsPercent(self.env.getCurrentPrice()) 231 | 232 | 233 | def plot_cum_returns(self): 234 | import matplotlib.pyplot as plt 235 | 236 | plt.figure(figsize=(10,6)) 237 | x = [i for i in range(len(self.cum_returns))] 238 | plt.plot(x, self.cum_returns) 239 | plt.show() 240 | 241 | def plot_env(self, states_to_plot=None): 242 | self.env.plot(states_to_plot) 243 | -------------------------------------------------------------------------------- /v2/env.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "code", 5 | "execution_count": null, 6 | "metadata": { 7 | "collapsed": true 8 | }, 9 | "outputs": [], 10 | "source": [ 11 | "'''\n", 12 | "\n", 13 | "### Cryptocurrency Trader Agent\n", 14 | "### UCB MIDS 2017 Winter Capstone Project\n", 15 | "### Ramsey Aweti, Shuang Chan, GuangZhi(Frank) Xie, Jason Xie\n", 16 | "\n", 17 | "### Class: \n", 18 | "### Environment\n", 19 | "### Purpose: \n", 20 | "### This is utility class used to simulate the cryptocurrency markets.\n", 21 | "### It maintains the state list of the environment.\n", 22 | "### Sample Usage:\n", 23 | "\n", 24 | "env = Environment(coin_name=\"ethereum\")\n", 25 | "print env.step()\n", 26 | "print env.step()\n", 27 | "print env.step()\n", 28 | "env.plot()\n", 29 | "\n", 30 | "'''\n", 31 | "\n", 32 | "import os\n", 33 | "import pandas as pd \n", 34 | "import numpy as np\n", 35 | "\n", 36 | "\n", 37 | "state_list = [\"current_price\", \"rolling_mean\", \"rolling_std\", \"cross_upper_band\", \"cross_lower_band\", \"upper_band\",\n", 38 | " \"lower_band\", \"price_over_sma\"]\n", 39 | "\n", 40 | "class Environment:\n", 41 | " \n", 42 | " # load pricing data\n", 43 | " # initialize the environment variables\n", 44 | " def __init__(self, coin_name=\"ethereum\", states=state_list, recent_k = 0):\n", 45 | " self.coin_name = coin_name\n", 46 | " self.states = states\n", 47 | "\n", 48 | " self.series = pd.read_csv(\"%s/cryptocurrencypricehistory/%s_price.csv\" \n", 49 | " % (os.path.dirname(os.path.abspath(__file__)), self.coin_name), \n", 50 | " parse_dates=[\"Date\"])\n", 51 | " \n", 52 | " self.series.index = self.series.sort_values(by=[\"Date\"]).index\n", 53 | " self.series = self.series.sort_index()\n", 54 | " \n", 55 | " if recent_k > 0:\n", 56 | " self.series = self.series[-recent_k:]\n", 57 | " self.series.index = [i for i in range(len(self.series))]\n", 58 | " \n", 59 | " self.length = len(self.series.index)\n", 60 | " self.current_index = 0\n", 61 | " self.__init()\n", 62 | "\n", 63 | " # deriving the features used for the state definition\n", 64 | " def __init(self):\n", 65 | " self.isDone = np.zeros(self.series[\"Open\"].shape, dtype=bool)\n", 66 | " self.isDone[-1] = True \n", 67 | "\n", 68 | " ### States\n", 69 | " self.rm = self.series[\"Open\"].rolling(window=20, center=False, min_periods=0).mean()\n", 70 | " self.rstd = self.series[\"Open\"].rolling(window=20, center=False, min_periods=0).std()\n", 71 | " self.upper_band, self.lower_band = self.rm + 2 * self.rstd, self.rm - 2 * self.rstd\n", 72 | "\n", 73 | " ### Mapping states to their names\n", 74 | " self.state_dict = {}\n", 75 | " self.state_dict[\"current_price\"] = self.series[\"Open\"]\n", 76 | " self.state_dict[\"rolling_mean\"] = self.rm\n", 77 | " self.state_dict[\"rolling_std\"] = self.rstd\n", 78 | " self.state_dict[\"cross_upper_band\"] = self.__crossUpperBand()\n", 79 | " self.state_dict[\"cross_lower_band\"] = self.__crossLowerBand()\n", 80 | " self.state_dict[\"upper_band\"] = self.upper_band\n", 81 | " self.state_dict[\"lower_band\"] = self.lower_band\n", 82 | " self.state_dict[\"price_over_sma\"] = self.series[\"Open\"]/self.rm\n", 83 | " \n", 84 | " \n", 85 | " def __crossUpperBand(self):\n", 86 | " crossUpperBand = [0]\n", 87 | " for i in range(1, len(self.series)):\n", 88 | " crossUpperBand.append(self.__checkCrossUpperBand(i)*1)\n", 89 | " return crossUpperBand\n", 90 | " \n", 91 | " \n", 92 | " def __crossLowerBand(self):\n", 93 | " crossLowerBand = [0]\n", 94 | " for i in range(1, len(self.series)):\n", 95 | " crossLowerBand.append(self.__checkCrossLowerBand(i)*1)\n", 96 | " return crossLowerBand\n", 97 | " \n", 98 | " \n", 99 | " def __checkCrossUpperBand(self, curr_index):\n", 100 | " return (\n", 101 | " curr_index - 1 >= 0\n", 102 | " and self.upper_band.loc[curr_index - 1] <= self.state_dict[\"current_price\"][curr_index]\n", 103 | " and self.upper_band.loc[curr_index] > self.state_dict[\"current_price\"][curr_index]\n", 104 | " )\n", 105 | " \n", 106 | " def __checkCrossLowerBand(self, curr_index):\n", 107 | " return (\n", 108 | " curr_index - 1 >= 0\n", 109 | " and self.lower_band.loc[curr_index - 1] >= self.state_dict[\"current_price\"][curr_index]\n", 110 | " and self.lower_band.loc[curr_index] < self.state_dict[\"current_price\"][curr_index]\n", 111 | " )\n", 112 | "\n", 113 | " ## This is the only place where the state should be exposed\n", 114 | " ''' \n", 115 | " isDone, state = env.step()\n", 116 | " '''\n", 117 | " # simulate a forward step in the environment, i.e.: moving one day\n", 118 | " def step(self):\n", 119 | " isDone = self.isDone[self.current_index]\n", 120 | " observation = []\n", 121 | " for state in self.states:\n", 122 | " observation.append(self.state_dict[state][self.current_index])\n", 123 | " if not isDone:\n", 124 | " self.current_index += 1\n", 125 | " return isDone, observation\n", 126 | "\n", 127 | " def getStates(self, states=None):\n", 128 | " if not states:\n", 129 | " states = self.states\n", 130 | " return [self.state_dict[state][self.current_index] for state in states]\n", 131 | "\n", 132 | " def getStateSpaceSize(self):\n", 133 | " return len(self.states)\n", 134 | " \n", 135 | " \n", 136 | " ## Add method to get current price as it is commonly used\n", 137 | " def getCurrentPrice(self):\n", 138 | " return self.state_dict[\"current_price\"][self.current_index]\n", 139 | " \n", 140 | "\n", 141 | " def plot(self, states_to_plot=None):\n", 142 | " import matplotlib.pyplot as plt\n", 143 | " if not states_to_plot:\n", 144 | " states_to_plot = self.states\n", 145 | "\n", 146 | " plt.figure()\n", 147 | " for state in states_to_plot:\n", 148 | " ax = self.state_dict[state].plot()\n", 149 | " ax.legend(self.states)\n", 150 | " plt.show()\n", 151 | "\n", 152 | " def reset(self):\n", 153 | " self.current_index = 0\n" 154 | ] 155 | } 156 | ], 157 | "metadata": { 158 | "kernelspec": { 159 | "display_name": "Python 2", 160 | "language": "python", 161 | "name": "python2" 162 | }, 163 | "language_info": { 164 | "codemirror_mode": { 165 | "name": "ipython", 166 | "version": 2 167 | }, 168 | "file_extension": ".py", 169 | "mimetype": "text/x-python", 170 | "name": "python", 171 | "nbconvert_exporter": "python", 172 | "pygments_lexer": "ipython2", 173 | "version": "2.7.11" 174 | } 175 | }, 176 | "nbformat": 4, 177 | "nbformat_minor": 2 178 | } 179 | -------------------------------------------------------------------------------- /v2/env.py: -------------------------------------------------------------------------------- 1 | ''' 2 | 3 | ### Cryptocurrency Trader Agent 4 | ### UCB MIDS 2017 Winter Capstone Project 5 | ### Ramsey Aweti, Shuang Chan, GuangZhi(Frank) Xie, Jason Xie 6 | 7 | ### Class: 8 | ### Environment 9 | ### Purpose: 10 | ### This is utility class used to simulate the cryptocurrency markets. 11 | ### It maintains the state list of the environment. 12 | ### Sample Usage: 13 | 14 | env = Environment(coin_name="ethereum") 15 | print env.step() 16 | print env.step() 17 | print env.step() 18 | env.plot() 19 | 20 | ''' 21 | 22 | import os 23 | import pandas as pd 24 | import numpy as np 25 | from utils import * 26 | 27 | 28 | state_list = ["current_price", "rolling_mean", "rolling_std", "cross_upper_band", "cross_lower_band", "upper_band", 29 | "lower_band", "price_over_sma"] 30 | 31 | class Environment: 32 | 33 | # load pricing data 34 | # initialize the environment variables 35 | def __init__(self, coin_name="ethereum", states=state_list, recent_k = 0): 36 | self.coin_name = coin_name 37 | self.states = states 38 | 39 | self.series = pd.read_csv("%s/cryptocurrencypricehistory/%s_price.csv" 40 | % (os.path.dirname(os.path.abspath(__file__)), self.coin_name), 41 | parse_dates=["Date"]) 42 | 43 | self.series.index = self.series.sort_values(by=["Date"]).index 44 | self.series = self.series.sort_index() 45 | 46 | if recent_k > 0: 47 | self.series = self.series[-recent_k:] 48 | self.series.index = [i for i in range(len(self.series))] 49 | 50 | self.length = len(self.series.index) 51 | self.current_index = 0 52 | self.__init() 53 | 54 | # deriving the features used for the state definition 55 | def __init(self): 56 | self.isDone = np.zeros(self.series["Open"].shape, dtype=bool) 57 | self.isDone[-1] = True 58 | 59 | ### States 60 | self.rm = self.series["Open"].rolling(window=20, center=False, min_periods=0).mean() 61 | self.rstd = self.series["Open"].rolling(window=20, center=False, min_periods=0).std() 62 | self.upper_band, self.lower_band = self.rm + 2 * self.rstd, self.rm - 2 * self.rstd 63 | 64 | ### Mapping states to their names 65 | self.state_dict = {} 66 | self.state_dict["current_price"] = self.series["Open"] 67 | self.state_dict["rolling_mean"] = self.rm 68 | self.state_dict["rolling_std"] = self.rstd 69 | self.state_dict["cross_upper_band"] = self.__crossUpperBand() 70 | self.state_dict["cross_lower_band"] = self.__crossLowerBand() 71 | self.state_dict["upper_band"] = self.upper_band 72 | self.state_dict["lower_band"] = self.lower_band 73 | self.state_dict["price_over_sma"] = self.series["Open"]/self.rm 74 | 75 | 76 | def __crossUpperBand(self): 77 | crossUpperBand = [0] 78 | for i in range(1, len(self.series)): 79 | crossUpperBand.append(self.__checkCrossUpperBand(i)*1) 80 | return crossUpperBand 81 | 82 | 83 | def __crossLowerBand(self): 84 | crossLowerBand = [0] 85 | for i in range(1, len(self.series)): 86 | crossLowerBand.append(self.__checkCrossLowerBand(i)*1) 87 | return crossLowerBand 88 | 89 | 90 | def __checkCrossUpperBand(self, curr_index): 91 | return ( 92 | curr_index - 1 >= 0 93 | and self.upper_band.loc[curr_index - 1] <= self.state_dict["current_price"][curr_index] 94 | and self.upper_band.loc[curr_index] > self.state_dict["current_price"][curr_index] 95 | ) 96 | 97 | def __checkCrossLowerBand(self, curr_index): 98 | return ( 99 | curr_index - 1 >= 0 100 | and self.lower_band.loc[curr_index - 1] >= self.state_dict["current_price"][curr_index] 101 | and self.lower_band.loc[curr_index] < self.state_dict["current_price"][curr_index] 102 | ) 103 | 104 | ## This is the only place where the state should be exposed 105 | ''' 106 | isDone, state = env.step() 107 | ''' 108 | # simulate a forward step in the environment, i.e.: moving one day 109 | def step(self): 110 | isDone = self.isDone[self.current_index] 111 | observation = [] 112 | for state in self.states: 113 | observation.append(self.state_dict[state][self.current_index]) 114 | if not isDone: 115 | self.current_index += 1 116 | return isDone, observation 117 | 118 | def getStates(self, states=None): 119 | if not states: 120 | states = self.states 121 | return [self.state_dict[state][self.current_index] for state in states] 122 | 123 | def getStateSpaceSize(self): 124 | return len(self.states) 125 | 126 | 127 | ## Add method to get current price as it is commonly used 128 | def getCurrentPrice(self): 129 | return self.state_dict["current_price"][self.current_index] 130 | 131 | def getFinalPrice(self): 132 | return self.state_dict["current_price"][self.length-1] 133 | 134 | def getPriceAt(self, index): 135 | if index < 0: 136 | return self.state_dict["current_price"][0] 137 | if index >= self.length: 138 | return self.getFinalPrice() 139 | return self.state_dict["current_price"][index] 140 | 141 | 142 | def plot(self, states_to_plot=None): 143 | import matplotlib.pyplot as plt 144 | if not states_to_plot: 145 | states_to_plot = self.states 146 | 147 | plt.figure() 148 | for state in states_to_plot: 149 | ax = self.state_dict[state].plot() 150 | ax.legend(states_to_plot) 151 | plt.show() 152 | 153 | def reset(self): 154 | self.current_index = 0 155 | 156 | def getReward(self, action): 157 | a = 0 158 | if action == Action.BUY: 159 | a = 1 160 | elif action == Action.SELL: 161 | a = -1 162 | 163 | price_t = self.getCurrentPrice() 164 | price_t_minus_1 = self.getPriceAt(self.current_index - 1) 165 | price_t_minus_n = self.getPriceAt(self.current_index - 10) 166 | 167 | r = (1 + a*(price_t - price_t_minus_1)/price_t_minus_1)*price_t_minus_1/price_t_minus_n 168 | return r 169 | 170 | 171 | 172 | -------------------------------------------------------------------------------- /v2/portfolio.py: -------------------------------------------------------------------------------- 1 | 2 | ''' 3 | 4 | ### Cryptocurrency Trader Agent 5 | ### UCB MIDS 2017 Winter Capstone Project 6 | ### Ramsey Aweti, Shuang Chan, GuangZhi(Frank) Xie, Jason Xie 7 | 8 | ### Class: 9 | ### Portfolio 10 | ### Purpose: 11 | ### This is utility class used to maintain action, reward and internal state definitions. 12 | ### 13 | ### Sample Usage: 14 | 15 | from env import * 16 | env = Environment(coin_name="ethereum") 17 | p = Portfolio(env) 18 | 19 | print env.getStates() ## initial step 20 | p._buy(10) 21 | print env.step() 22 | print p.getCurrentHoldings() 23 | 24 | ''' 25 | 26 | import numpy as np 27 | from utils import * 28 | 29 | 30 | # internal state 31 | state_list = ["coin", "cash", "total_value", "is_holding_coin", "return_since_entry"] 32 | spread = 0.01 # 1 bps 33 | 34 | def _round_up(v): 35 | return (math.ceil(v*10000)/10000) 36 | 37 | def _round_down(v): 38 | return (math.floor(v*10000)/10000) 39 | 40 | class Portfolio: 41 | 42 | # initialize the portfolio variables 43 | def __init__(self, num_coins_per_order=10.0, states=state_list, verbose=False, final_price=0.0): 44 | self.verbose = verbose 45 | self.final_price = final_price 46 | self.portfolio_coin = 0.0 47 | self.portfolio_cash = 0.0 48 | self.num_coins_per_order = num_coins_per_order 49 | self.states = states 50 | 51 | ### Mapping states to their names 52 | self.state_dict = {} 53 | self.state_dict["coin"] = self.portfolio_coin 54 | self.state_dict["cash"] = self.portfolio_cash 55 | self.state_dict["total_value"] = self.portfolio_cash 56 | self.state_dict["is_holding_coin"] = 0 57 | self.state_dict["return_since_entry"] = 0 58 | 59 | self.bought_price = 0.0 60 | 61 | self.cash_used = 0.0 62 | 63 | def __buy(self, current_price): 64 | if not current_price: 65 | return 0 66 | 67 | buy_price = current_price * (1 + spread) 68 | 69 | coin_to_buy = self.num_coins_per_order 70 | 71 | if self.verbose: 72 | print "original coin:{}, original cash:{}, price:{}, original cash used:{}".format( 73 | self.portfolio_coin, self.portfolio_cash, buy_price, self.cash_used) 74 | 75 | self.portfolio_coin += coin_to_buy 76 | self.cash_used += coin_to_buy * buy_price 77 | 78 | if self.verbose: 79 | print "coin to buy:{}, coin now:{}, cash now:{}, cash used now:{}".format( 80 | coin_to_buy, self.portfolio_coin, self.portfolio_cash, self.cash_used) 81 | 82 | return coin_to_buy, buy_price 83 | 84 | def __sell(self, current_price): 85 | if not current_price: 86 | return 0 87 | 88 | sell_price = current_price * (1 - spread) 89 | 90 | coin_to_sell = min(self.num_coins_per_order, self.portfolio_coin) 91 | 92 | if self.verbose: 93 | print "original coin:{}, original cash:{}, price:{}, original cash used:{}".format( 94 | self.portfolio_coin, self.portfolio_cash, buy_price, self.cash_used) 95 | 96 | self.portfolio_coin -= coin_to_sell 97 | self.portfolio_cash += coin_to_sell * sell_price 98 | 99 | if self.verbose: 100 | print "coin to buy:{}, coin now:{}, cash now:{}, cash used now:{}".format( 101 | coin_to_buy, self.portfolio_coin, self.portfolio_cash, self.cash_used) 102 | 103 | return coin_to_sell, sell_price 104 | 105 | # reset portfolio 106 | def reset(self): 107 | self.__init__(num_coins_per_order=self.num_coins_per_order, 108 | states=self.states, verbose=self.verbose, final_price=self.final_price) 109 | 110 | # return internal state 111 | def getStates(self, states=None): 112 | if not states: 113 | states = self.states 114 | return [self.state_dict[state] for state in states] 115 | 116 | # reward defintion 117 | def getReward(self): 118 | #return self.reward 119 | if self.cash_used == 0.0: 120 | return 0.0 121 | return (self.getCurrentValue(self.final_price) - self.cash_used)/self.cash_used 122 | 123 | # apply action (buy, sell or hold) to the portfolio 124 | # update the internal state after the action 125 | def apply_action(self, current_price, action): 126 | self.state_dict["total_value"] = self.getCurrentValue(current_price) 127 | if self.verbose: 128 | print "Action start", action, "Total value before action", self.state_dict["total_value"] 129 | 130 | self.reward = self.getCurrentValue(self.final_price) - self.state_dict["total_value"] # Reward for HOLD 131 | if action == Action.BUY: 132 | coin_to_buy, buy_price = self.__buy(current_price) 133 | if coin_to_buy > 0: 134 | self.bought_price = buy_price 135 | self.reward = self.getCurrentValue(self.final_price)-self.state_dict["total_value"]-spread * current_price * coin_to_buy - self.cash_used # Reward for BUY 136 | else: 137 | action = Action.HOLD 138 | 139 | elif action == Action.SELL: 140 | coin_to_sell, sell_price = self.__sell(current_price) 141 | if coin_to_sell > 0: 142 | #self.reward = (sell_price - self.bought_price) * coin_to_sell # Reward for SELL 143 | self.reward = self.state_dict["total_value"] - self.cash_used 144 | else: 145 | action = Action.HOLD 146 | 147 | # Update states 148 | self.state_dict["coin"] = self.portfolio_coin 149 | self.state_dict["cash"] = self.portfolio_cash 150 | self.state_dict["total_value"] = self.getCurrentValue(current_price) 151 | self.state_dict["is_holding_coin"] = (self.portfolio_coin > 0)*1 152 | self.state_dict["return_since_entry"] = self.getReturnsPercent(current_price) 153 | 154 | if self.verbose: 155 | print "Action end:", action, "Reward:", self.getReward() 156 | 157 | return action 158 | 159 | 160 | def getCurrentValue(self, current_price): 161 | sell_price = current_price * (1 - spread) 162 | return self.portfolio_coin * sell_price + self.portfolio_cash 163 | 164 | def getReturnsPercent(self, current_price): 165 | #return 100 * (self.getCurrentValue(current_price) - self.starting_cash) / self.starting_cash 166 | if self.cash_used == 0.0: 167 | return 0.0 168 | return 100 * (self.getCurrentValue(current_price) - self.cash_used) / self.cash_used 169 | 170 | def getCurrentHoldings(self, current_price): 171 | return "%.2f coins, %.2f cash, %.2f current value, %.2f percent returns" \ 172 | % (self.portfolio_coin, self.portfolio_cash, self.getCurrentValue(current_price), 173 | self.getReturnsPercent(current_price)) 174 | 175 | def getActionSpaceSize(self): 176 | return len(list(Action)) 177 | 178 | def getStateSpaceSize(self): 179 | return len(self.states) 180 | 181 | def getCashUsed(self): 182 | return self.cash_used 183 | 184 | 185 | 186 | -------------------------------------------------------------------------------- /v2/run_benchmarks.py: -------------------------------------------------------------------------------- 1 | from env import * 2 | from simple_agents import * 3 | from portfolio import * 4 | 5 | def run_random_agent(coin_name="ethereum", num_coins_per_order=100, recent_k=0): 6 | ra = RandomAgent(Action) 7 | env = Environment(coin_name=coin_name, recent_k=recent_k) 8 | portfolio = Portfolio(num_coins_per_order = num_coins_per_order) 9 | 10 | is_done = False 11 | state = env.getStates() 12 | 13 | while not is_done: 14 | action = ra.act() 15 | portfolio.apply_action(env.getCurrentPrice(), action) 16 | is_done, state = env.step() 17 | 18 | print "Final holdings:", portfolio.getCurrentHoldings(env.getCurrentPrice()) 19 | return portfolio.getReturnsPercent(env.getCurrentPrice()) 20 | 21 | 22 | def run_bollingerband_agent(coin_name="ethereum", num_coins_per_order=100, recent_k=0): 23 | bba = BollingerBandAgent() 24 | env = Environment(coin_name=coin_name, recent_k=recent_k, \ 25 | states=["cross_upper_band", "cross_lower_band"]) 26 | portfolio = Portfolio(num_coins_per_order = num_coins_per_order) 27 | 28 | is_done = False 29 | state = env.getStates() 30 | 31 | while not is_done: 32 | # print portfolio.getCurrentHoldings() 33 | action = bba.act(state) 34 | # print action 35 | portfolio.apply_action(env.getCurrentPrice(), action) 36 | is_done, state = env.step() 37 | 38 | print "Final holdings:", portfolio.getCurrentHoldings(env.getCurrentPrice()) 39 | return portfolio.getReturnsPercent(env.getCurrentPrice()) 40 | 41 | 42 | def run_alwaysbuy_agent(coin_name="ethereum", num_coins_per_order=100, recent_k=0): 43 | env = Environment(coin_name=coin_name, recent_k=recent_k) 44 | portfolio = Portfolio(num_coins_per_order = num_coins_per_order) 45 | 46 | is_done = False 47 | state = env.getStates() 48 | 49 | while not is_done: 50 | portfolio.apply_action(env.getCurrentPrice(), Action.BUY) 51 | is_done, state = env.step() 52 | 53 | print "Final holdings:", portfolio.getCurrentHoldings(env.getCurrentPrice()) 54 | return portfolio.getReturnsPercent(env.getCurrentPrice()) 55 | 56 | -------------------------------------------------------------------------------- /v2/simple_agents.py: -------------------------------------------------------------------------------- 1 | import random 2 | from portfolio import Action 3 | 4 | ''' 5 | ra = RandomAgent(Action) 6 | print ra.act() 7 | print ra.act() 8 | print ra.act() 9 | ''' 10 | class RandomAgent: 11 | def __init__(self, Action): 12 | self.Action = Action 13 | 14 | def act(self, state=None): 15 | return random.choice(list(self.Action)) 16 | 17 | ''' 18 | bba = BollingerBandAgent(Action) 19 | print bba.act([0, 0]) 20 | print bba.act([1, 0]) 21 | print bba.act([0, 1]) 22 | ''' 23 | class BollingerBandAgent: 24 | 25 | def act(self, state): 26 | cross_upper_band, cross_lower_band = state 27 | if cross_upper_band: 28 | return Action.SELL 29 | if cross_lower_band: 30 | return Action.BUY 31 | return Action.HOLD 32 | 33 | 34 | -------------------------------------------------------------------------------- /v2/utils.py: -------------------------------------------------------------------------------- 1 | import math 2 | from enum import Enum 3 | 4 | # action list 5 | class Action(Enum): 6 | HOLD=0 7 | BUY=1 8 | SELL=2 9 | 10 | def _round_up(v): 11 | return (math.ceil(v*10000)/10000) 12 | 13 | def _round_down(v): 14 | return (math.floor(v*10000)/10000) --------------------------------------------------------------------------------