From 59662fe76ae95bec0a32a2f4a89f833a6d07acc8 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Tue, 27 Feb 2018 16:59:45 +0100 Subject: [PATCH] Mariam History Added --- .vs/AAWebPlatform/v15/.suo | Bin 65536 -> 68608 bytes Ecosystem.js | 98 +++++++++++++++++++++++++++++++++++++ FileCloud.js | 2 + Panels/ChartLayersPanel.js | 19 ++++++- TimelineChart.js | 36 +++++++++++++- index.html | 3 ++ server.js | 2 +- 7 files changed, 156 insertions(+), 4 deletions(-) diff --git a/.vs/AAWebPlatform/v15/.suo b/.vs/AAWebPlatform/v15/.suo index 30f85c86dc81bd15d2796d18468c8a0605f36fc5..a3d343eb56d26d04684115ba7e8bf1348d0eac6a 100644 GIT binary patch delta 4875 zcmd5<3s6+&72bc@1r`=q5LR9b3nDJ^5R_R#h%79=@Bt_&raFq1HX)!q9U%>@sj)^8 z*n6~zjWHICO)5!{>%?em0z%bb491xHNS%UJiTD_!*p~R9=UnbJ8%wO6X*2z2zWbm5 zasL0@^PThG|5_{x%d3j|L@$+0CX*u`3=R%rC1VJ`J(+hI3xptfpndmm_U`-Zdr%_J zgm$|a)&Y0q)ygqADF`a;(v-{|MOgEEgv%-vTD|ar#Q~VYuiA)GEJBIUB4QB!2;6DV zgtZ#sgor|fAu;f}+oY6A|@vOZ!>@@SNa8->_M+)%&7%^a~! z+)zJpqeqbUh#Tr7ZXyv82;zn~B+iJNu?R9LTqZNhW}`sdj6zI6=n&%(-iQE%L=`Pc zg*?9ijw{A7cet;Z5J7$9)glDRQkjSCEW~`V|7omYkut=6x!561Tw%=|qmuaafHvhA zX0c|DL;+>g*cA*OdO-}&qetQtWSyZpRhhH%4e}Y2f3;- z)}j!;**SyJPT8dSzuE5PCfZMq91Ur``XO-n<+Hbaf<3sLZ}vutEKw98|Zui=0d1_Hs8 zJVL=psY)^hE9}t!!kZd|H0+ou4pJcTu|b~95%c}wR(x4-22)c6%58d;FJNN{Kj7EN zT!eg`Yct4p@pp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 z5cHm@hBI%wL(kC=Vf&vJ@hnn!_njms)tHS4Y&{r$VuPyhUvS`}BPc$5Np;yyJA$$j zHV)R|AqLQW5CIWgNicRTh`yeww*D@|IM-n82=Qs))*+*jTm`p@%ikw>veV_`&EMwg zgr2zxY#NK;-FJ?guk%9f$0o zM*xGeFY`e6g+J^bsWJt*vOKg;4nye+Kr+%YwbF3Ykv(U+?Z8&U>%l(go3H5G)tmo; zWw#pHdLjTm|G9=anr6GQLQrhc2qE`>$-r{I3XX?pAgaw5c7E*#Wp|5U_c#7*E3U|g zH6w0NzF+HP{WGzi4#kGE%R`ay%!u;;^4El>)qLN`HWxNTbiKCcEDLCJ PWkFb9TeG6TugT-TK8>UM diff --git a/Ecosystem.js b/Ecosystem.js index e2bb15b79..5cbe63d29 100644 --- a/Ecosystem.js +++ b/Ecosystem.js @@ -355,6 +355,104 @@ function newEcosystem() { sas: '?sv=2017-04-17&ss=f&srt=sco&sp=r&se=2018-12-31T19:28:33Z&st=2018-02-22T11:28:33Z&spr=https&sig=YaprSp9zO%2Fsz0nPPWwPMqPACxZTnYhSWKApfun%2Bfez4%3D', fileUri: 'https://' + 'aatom' + '.file.core.windows.net' } + }, + { + codeName: "AAMariam", + displayName: "Mariam", + type: "Trading", + version: { + number: "1.0.0", + status: "Mantained", // Discontinued + }, + products: { + product: [{ + codeName: "Trading History", + displayName: "Mariam Trading History", + description: "General information about Mariam trading history.", + storageAccount: "aamariam", + filePath: "@Exchange/Mariam/dataSet.V1/Output/Trading-Process", + fileName: "Execution.History.json", + exchangeList: { + exchange: [{ + name: "Poloniex", + datetimeRange: { + minDatetime: "2017-02-19 19:15:00.000 GMT+0000", + maxDatetime: "2018-02-13 10:10:00.000 GMT+0000" + } + }] + }, + layers: { + layer: [{ + codeName: "Trading History", + displayName: "Mariam Trading History", + exchangeList: ["Poloniex"], + validPeriods: ["24-hs", "12-hs", "08-hs", "06-hs", "04-hs", "03-hs", "02-hs", "01-hs"], + plotter: { + devTeam: "AAMasters", + repo: "AAMariam-Plotter", + moduleName: "History", + target: "Timeline" + } + }] + } + }, { + codeName: "Trading Details", + displayName: "Mariam Trading Details", + description: "Detailed information about Mariam execution.", + storageAccount: "aamariam", + filePath: "@Exchange/Mariam/dataSet.V1/Output/Trading-Process//@Year/@Month/@Day/@Hour/@Minute", + fileName: "Execution.Context.json", + exchangeList: { + exchange: [{ + name: "Poloniex", + datetimeRange: { + minDatetime: "2017-02-19 19:15:00.000 GMT+0000", + maxDatetime: "2018-02-13 10:10:00.000 GMT+0000" + } + }] + }, + layers: { + layer: [{ + codeName: "Trading Details", + displayName: "Mariam Trading Details", + exchangeList: ["Poloniex"], + validPeriods: ["24-hs", "12-hs", "08-hs", "06-hs", "04-hs", "03-hs", "02-hs", "01-hs"], + plotter: { + devTeam: "AAMasters", + repo: "AAMariam-Plotter", + moduleName: "Details", + target: "Timeline" + } + }] + } + }] + }, + processes: + { + process: [{ + name: "Trading-Process", + description: "Read trades files and generates one minute candles and volumes files for each day." + }] + }, + directDependencies: [], + directDependents: [], + collaboratorsList: [], + github: { + org: "AAMasters", + repos: { + repo: [{ + name: "AABruce", + description: "Produces two data-sets with candles and volumes for all markets at all exchanges.", + openIssues: 0, + openPullRequests: 0, + contributors: 1 + }] + } + }, + storage: { + sas: '?sv=2017-07-29&ss=f&srt=sco&sp=r&se=2018-12-30T23:44:52Z&st=2018-02-25T15:44:52Z&spr=https&sig=0pzOTcVAAOkgH7C4KmA1Rbs15kyjvVC1XFCsLQYjXKU%3D', + fileUri: 'https://' + 'aamariam' + '.file.core.windows.net' + } } ] } diff --git a/FileCloud.js b/FileCloud.js index 7da02dbb7..a9aa41ade 100644 --- a/FileCloud.js +++ b/FileCloud.js @@ -34,6 +34,8 @@ function newFileCloud() { filePath = filePath.replace("@Year", pDatetime.getUTCFullYear()); filePath = filePath.replace("@Month", pad(pDatetime.getUTCMonth() + 1, 2)); filePath = filePath.replace("@Day", pad(pDatetime.getUTCDate(), 2)); + filePath = filePath.replace("@Hour", pad(pDatetime.getUTCHours(), 2)); + filePath = filePath.replace("@Minute", pad(pDatetime.getUTCMinutes(), 2)); } diff --git a/Panels/ChartLayersPanel.js b/Panels/ChartLayersPanel.js index c303819a3..c01488e4d 100644 --- a/Panels/ChartLayersPanel.js +++ b/Panels/ChartLayersPanel.js @@ -14,6 +14,8 @@ function newChartLayersPanel() { OLIVIA_VOLUMES: 'Olivia Volumes', TOM_CANDLE_STAIRS: 'Tom Candle-Stairs', TOM_VOLUME_STAIRS: 'Tom Volume-Stairs', + MARIAM_TRADE_HISTORY: 'Mariam Trades History', + MARIAM_TRADES_DETAILS: 'Mariam Trades Details', ATH: 'All-time Highs and Lows', HIGH_LOWS: 'High and Lows', FORECAST: 'Forecast', @@ -63,7 +65,22 @@ function newChartLayersPanel() { var buttonPosition; - var buttonNames = [LAYER_NAMES.OLIVIA_CANDLES, LAYER_NAMES.OLIVIA_VOLUMES, LAYER_NAMES.TOM_CANDLE_STAIRS, LAYER_NAMES.TOM_VOLUME_STAIRS, LAYER_NAMES.ATH, LAYER_NAMES.HIGH_LOWS, LAYER_NAMES.FORECAST, LAYER_NAMES.ORDER_BOOKS, LAYER_NAMES.CANDLE_STAIRS, LAYER_NAMES.VOLUME_STAIRS, LAYER_NAMES.BUY_SELL_BALANCE, LAYER_NAMES.LINEAR_REGRESION_CURVE]; + var buttonNames = [ + LAYER_NAMES.OLIVIA_CANDLES, + LAYER_NAMES.OLIVIA_VOLUMES, + LAYER_NAMES.TOM_CANDLE_STAIRS, + LAYER_NAMES.MARIAM_TRADES_DETAILS, + LAYER_NAMES.MARIAM_TRADE_HISTORY, + LAYER_NAMES.MARIAM_TRADE_HISTORY, + LAYER_NAMES.ATH, + LAYER_NAMES.HIGH_LOWS, + LAYER_NAMES.FORECAST, + LAYER_NAMES.ORDER_BOOKS, + LAYER_NAMES.CANDLE_STAIRS, + LAYER_NAMES.VOLUME_STAIRS, + LAYER_NAMES.BUY_SELL_BALANCE, + LAYER_NAMES.LINEAR_REGRESION_CURVE + ]; var lastY = 5; buttons = []; diff --git a/TimelineChart.js b/TimelineChart.js index d2a578d1b..e168736f8 100644 --- a/TimelineChart.js +++ b/TimelineChart.js @@ -191,7 +191,7 @@ function newTimelineChart() { layerAAMastersAATomCandleStairs.container.frame.position.x = timelineChart.container.frame.width / 2 - layerAAMastersAATomCandleStairs.container.frame.width / 2; layerAAMastersAATomCandleStairs.container.frame.position.y = timelineChart.container.frame.height / 2 - layerAAMastersAATomCandleStairs.container.frame.height / 2; - layerStatus = chartLayersPanel.getLayerStatus(chartLayersPanel.layerNames.OLIVIA_CANDLES); + layerStatus = chartLayersPanel.getLayerStatus(chartLayersPanel.layerNames.TOM_CANDLE_STAIRS); layerAAMastersAATomCandleStairs.initialize(DEFAULT_EXCHANGE, DEFAULT_MARKET, INITIAL_DATE, INITIAL_TIME_PERIOD, layerStatus, onOliviaCandlesInitialized); @@ -223,7 +223,7 @@ function newTimelineChart() { layerAAMastersAATomVolumeStairs.container.frame.position.x = timelineChart.container.frame.width / 2 - layerAAMastersAATomVolumeStairs.container.frame.width / 2; layerAAMastersAATomVolumeStairs.container.frame.position.y = timelineChart.container.frame.height / 2 - layerAAMastersAATomVolumeStairs.container.frame.height / 2; - layerStatus = chartLayersPanel.getLayerStatus(chartLayersPanel.layerNames.OLIVIA_VOLUMES); + layerStatus = chartLayersPanel.getLayerStatus(chartLayersPanel.layerNames.TOM_VOLUME_STAIRS); layerAAMastersAATomVolumeStairs.initialize(DEFAULT_EXCHANGE, DEFAULT_MARKET, INITIAL_DATE, INITIAL_TIME_PERIOD, layerStatus, onOliviaVolumeStairsInitialized); @@ -238,6 +238,38 @@ function newTimelineChart() { + /* AAMasters AAMariam Trading History */ + + let layerAAMastersAAMariamTradingHistory = newAAMastersAAMariamTradingHistory(); + + function loadVolumeStairs() { + + layerAAMastersAAMariamTradingHistory.container.displacement.parentDisplacement = timelineChart.container.displacement; + layerAAMastersAAMariamTradingHistory.container.zoom.parentZoom = timelineChart.container.zoom; + layerAAMastersAAMariamTradingHistory.container.frame.parentFrame = timelineChart.container.frame; + + layerAAMastersAAMariamTradingHistory.container.parentContainer = timelineChart.container; + + layerAAMastersAAMariamTradingHistory.container.frame.width = timelineChart.container.frame.width * 1; + layerAAMastersAAMariamTradingHistory.container.frame.height = timelineChart.container.frame.height * 1; + + layerAAMastersAAMariamTradingHistory.container.frame.position.x = timelineChart.container.frame.width / 2 - layerAAMastersAAMariamTradingHistory.container.frame.width / 2; + layerAAMastersAAMariamTradingHistory.container.frame.position.y = timelineChart.container.frame.height / 2 - layerAAMastersAAMariamTradingHistory.container.frame.height / 2; + + layerStatus = chartLayersPanel.getLayerStatus(chartLayersPanel.layerNames.MARIAM_TRADE_HISTORY); + + layerAAMastersAAMariamTradingHistory.initialize(DEFAULT_EXCHANGE, DEFAULT_MARKET, INITIAL_DATE, INITIAL_TIME_PERIOD, layerStatus, onOliviaVolumeStairsInitialized); + + function onOliviaVolumeStairsInitialized() { + + addLayers(); + splashScreenNeeded = false; // This is when we dont need a splash screen anymore! + + } + + } + + /* All Time Layer */ /* diff --git a/index.html b/index.html index de53c2552..d3da5c2d3 100644 --- a/index.html +++ b/index.html @@ -10,6 +10,9 @@ + + + diff --git a/server.js b/server.js index 069cfb7ef..2ddfe3e83 100644 --- a/server.js +++ b/server.js @@ -30,7 +30,7 @@ function onContent (error, result) { return; */ -let debugMode = false; +let debugMode = true; let githubPages = new Map; //'use strict';