Commit 6f228dda authored by Ahmad Nemati's avatar Ahmad Nemati

git pu

parent 83f721eb
...@@ -181,8 +181,12 @@ function run(data, config, risk, pfTrade, riskFreeLevel, detail, loss, durs, max ...@@ -181,8 +181,12 @@ function run(data, config, risk, pfTrade, riskFreeLevel, detail, loss, durs, max
let allDonePer=0 let allDonePer=0
let allLongDone=0 let allLongDone=0
let allLongDonePer=0 let allLongDonePer=0
let lossLongDone=0
let lossLongDonePer=0
let allShortDone=0 let allShortDone=0
let allShortDonePer=0 let allShortDonePer=0
let lossShortDone=0
let lossShortDonePer=0
let lossDonePer=0 let lossDonePer=0
let lossPlusDone=0 let lossPlusDone=0
let lossPlusDonePer=0 let lossPlusDonePer=0
...@@ -860,10 +864,18 @@ function run(data, config, risk, pfTrade, riskFreeLevel, detail, loss, durs, max ...@@ -860,10 +864,18 @@ function run(data, config, risk, pfTrade, riskFreeLevel, detail, loss, durs, max
lossDone++ lossDone++
lossDonePer=lossDonePer+data[i].profit-0.1 lossDonePer=lossDonePer+data[i].profit-0.1
allDonePer=allDonePer+data[i].profit-0.1 allDonePer=allDonePer+data[i].profit-0.1
if (data[i].side === 'LONG') if (data[i].side === 'LONG') {
allLongDonePer=allLongDonePer+data[i].profit-0.1 allLongDonePer = allLongDonePer + data[i].profit - 0.1
else
allShortDonePer=allShortDonePer+data[i].profit-0.1 lossLongDone++
lossLongDonePer=lossLongDonePer+(data[i].profit+-0.1)
}
else {
allShortDonePer = allShortDonePer + data[i].profit - 0.1
lossShortDone++
lossShortDonePer=lossShortDonePer+(data[i].profit+-0.1)
}
if (data[i].profit>0.1) if (data[i].profit>0.1)
{ {
lossPlusDone++ lossPlusDone++
...@@ -1029,6 +1041,10 @@ function run(data, config, risk, pfTrade, riskFreeLevel, detail, loss, durs, max ...@@ -1029,6 +1041,10 @@ function run(data, config, risk, pfTrade, riskFreeLevel, detail, loss, durs, max
lossDonePer:lossDonePer, lossDonePer:lossDonePer,
lossPlusDone:lossPlusDone, lossPlusDone:lossPlusDone,
lossPlusDonePer:lossPlusDonePer, lossPlusDonePer:lossPlusDonePer,
lossLongDone:lossLongDone,
lossLongDonePer:lossLongDonePer,
lossShortDone:lossShortDone,
lossShortDonePer:lossShortDonePer,
avgLevel: maxLevel / total, avgLevel: maxLevel / total,
maxLevel: maxLevel, maxLevel: maxLevel,
dur: dur, dur: dur,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment