diff --git a/SimulationExecutionPanel.js b/SimulationExecutionPanel.js index e7d6ddff4..e85d6d5e5 100644 --- a/SimulationExecutionPanel.js +++ b/SimulationExecutionPanel.js @@ -26,7 +26,7 @@ function newAAMastersPlottersTradingSimulationSimulationExecutionSimulationExecu function initialize() { thisObject.container.frame.width = UI_PANEL.WIDTH.NORMAL; - thisObject.container.frame.height = UI_PANEL.HEIGHT.NORMAL * 2; + thisObject.container.frame.height = UI_PANEL.HEIGHT.NORMAL * 2.5; thisObject.container.frame.position.x = viewPort.visibleArea.topLeft.x + thisObject.container.frame.width * 4; thisObject.container.frame.position.y = viewPort.visibleArea.topRight.y; diff --git a/TradingSimulation.js b/TradingSimulation.js index 3182189b1..1e30b421d 100644 --- a/TradingSimulation.js +++ b/TradingSimulation.js @@ -346,6 +346,8 @@ record.minimunBalanceB = dailyFile[i][31]; record.maximunBalanceB = dailyFile[i][32]; record.baseAsset = dailyFile[i][33]; + record.positionPeriods = dailyFile[i][34]; + record.positionDays = dailyFile[i][35]; if (record.begin >= farLeftDate.valueOf() && record.end <= farRightDate.valueOf()) { @@ -443,6 +445,8 @@ record.minimunBalanceB = marketFile[i][31]; record.maximunBalanceB = marketFile[i][32]; record.baseAsset = marketFile[i][33]; + record.positionPeriods = marketFile[i][34]; + record.positionDays = marketFile[i][35]; if (record.begin >= leftDate.valueOf() && record.end <= rightDate.valueOf()) { diff --git a/TradingSimulationPanel.js b/TradingSimulationPanel.js index 1f3d5431e..331233ad9 100644 --- a/TradingSimulationPanel.js +++ b/TradingSimulationPanel.js @@ -28,7 +28,7 @@ function newAAMastersPlottersTradingSimulationTradingSimulationTradingSimulation function initialize() { thisObject.container.frame.width = UI_PANEL.WIDTH.NORMAL * 2; - thisObject.container.frame.height = UI_PANEL.HEIGHT.NORMAL * 2; + thisObject.container.frame.height = UI_PANEL.HEIGHT.NORMAL * 2.5; thisObject.container.frame.position.x = viewPort.visibleArea.topLeft.x + thisObject.container.frame.width * 1; thisObject.container.frame.position.y = viewPort.visibleArea.topRight.y; @@ -107,7 +107,7 @@ function newAAMastersPlottersTradingSimulationTradingSimulationTradingSimulation y = y + increment; y = y + increment; - printLabel('Current Trade', X_AXIS, frameTitleHeight + frameBodyHeight * y, '1', 14); + printLabel('Current Position', X_AXIS, frameTitleHeight + frameBodyHeight * y, '1', 14); y = y + increment; printLabel('Size', X_AXIS, frameTitleHeight + frameBodyHeight * y, '0.60'); @@ -132,7 +132,7 @@ function newAAMastersPlottersTradingSimulationTradingSimulationTradingSimulation y = y + increment; y = y + increment; - printLabel('Latest Trade', X_AXIS, frameTitleHeight + frameBodyHeight * y, '1', 14); + printLabel('Latest Position', X_AXIS, frameTitleHeight + frameBodyHeight * y, '1', 14); y = y + increment; printLabel('Profit / Loss', X_AXIS, frameTitleHeight + frameBodyHeight * y, '0.60'); @@ -144,6 +144,15 @@ function newAAMastersPlottersTradingSimulationTradingSimulationTradingSimulation y = y + increment; printLabel((currentRecord.lastTradeROI).toFixed(2) + ' % ', X_AXIS, frameTitleHeight + frameBodyHeight * y, '1.00', 14); + y = y + increment; + printLabel('Periods', X_AXIS, frameTitleHeight + frameBodyHeight * y, '0.60'); + y = y + increment; + printLabel((currentRecord.positionPeriods), X_AXIS, frameTitleHeight + frameBodyHeight * y, '1.00', 14); + + y = y + increment; + printLabel('Days', X_AXIS, frameTitleHeight + frameBodyHeight * y, '0.60'); + y = y + increment; + printLabel((currentRecord.positionDays).toFixed(2), X_AXIS, frameTitleHeight + frameBodyHeight * y, '1.00', 14);