Commit aee7adb5 authored by Ahmad Nemati's avatar Ahmad Nemati

git pull

parent 49f0cb8c
...@@ -23,7 +23,7 @@ let dates = [] ...@@ -23,7 +23,7 @@ let dates = []
for (let i = 0; i < year.length; i++) { for (let i = 0; i < year.length; i++) {
for (let j = 0; j < month.length; j++) { for (let j = 0; j < month.length; j++) {
let t = year[i] + '-' + month[j] let t = year[i] + '-' + month[j]
if (!(t === '2017-01' || t === '2017-02' || t === '2017-03' || t === '2017-04' || t === '2017-05' || t === '2017-06' || t === '2017-07' || t === '2017-08' || t === '2022-05' || t === '2022-06' || t === '2022-07' || t === '2022-08' || t === '2022-09' || t === '2022-10' || t === '2022-11' || t === '2022-12')) // if (!(t === '2017-01' || t === '2017-02' || t === '2017-03' || t === '2017-04' || t === '2017-05' || t === '2017-06' || t === '2017-07' || t === '2017-08' || t === '2022-05' || t === '2022-06' || t === '2022-07' || t === '2022-08' || t === '2022-09' || t === '2022-10' || t === '2022-11' || t === '2022-12'))
dates.push({date: t, profit: 0, count: 0, longCount: 0, shortCount: 0, longProfit: 0, shortProfit: 0}) dates.push({date: t, profit: 0, count: 0, longCount: 0, shortCount: 0, longProfit: 0, shortProfit: 0})
} }
} }
...@@ -213,7 +213,7 @@ async function run() { ...@@ -213,7 +213,7 @@ async function run() {
for (let i = 0; i < dates.length; i++) for (let i = 0; i < dates.length; i++)
sumAll = sumAll + dates[i].count sumAll = sumAll + dates[i].count
console.log(arrNew) console.log(arrDate)
// for (let i=0;i<arr.length;i++) // for (let i=0;i<arr.length;i++)
// if (arr[i].date.includes('2019-08') || arr[i].date.includes('2019-09')) // if (arr[i].date.includes('2019-08') || arr[i].date.includes('2019-09'))
// console.log(arr[i]) // console.log(arr[i])
......
...@@ -151,10 +151,10 @@ async function run() { ...@@ -151,10 +151,10 @@ async function run() {
// console.log('Balance ->',balance) // console.log('Balance ->',balance)
// console.log('Worth ->',arrNew[0]) // console.log('Worth ->',arrNew[0])
let worth = (balance - lastBalance) / (arrDate[0].sum-1000) let worth = (balance - lastBalance) / (arrNew[0].sum-1000)
if (worth < base) { if (worth < base) {
base = worth base = worth
console.log(arrDate[0].sum-1000, balance - lastBalance, worth) console.log(arrNew[0].sum-1000, balance - lastBalance, worth)
let arr5 = [] let arr5 = []
for (let f = 0; f < size; f++) { for (let f = 0; f < size; f++) {
arr5.push(com[f]) arr5.push(com[f])
...@@ -163,7 +163,7 @@ async function run() { ...@@ -163,7 +163,7 @@ async function run() {
// let z={maxReserve:arrNew[0].sum,balance:balance,bad:base} // let z={maxReserve:arrNew[0].sum,balance:balance,bad:base}
// //
// await createfileADV(JSON.stringify(z)) // await createfileADV(JSON.stringify(z))
await lastCheck(arrDate[0].sum, balance - lastBalance, base, arr5) await lastCheck(arrNew[0].sum, balance - lastBalance, base, arr5)
} }
// let start=false // let start=false
// let arr2=[] // let arr2=[]
......
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