Commit bb34606d authored by Ahmad Nemati's avatar Ahmad Nemati

init

parent 5eb7f22d
......@@ -80,36 +80,36 @@ async function run(name, directory, timestamp) {
if (name === 'compound1000' || name === 'allocatedReserveCompoundUnder3' || name === 'allocatedReserveCompoundUnder2')
last = _.orderBy(arr2, ['CompoundPerMonthDrawDown'], ['desc']);
if (name === 'allocatedReservePerMonthUnder2' || name === 'allocatedReservePerMonthUnder3') {
let arr20Max = []
for (let i = 0; i < last.length; i++) {
if (name === 'allocatedReservePerMonthUnder2')
alocatedReserve = 2
else
alocatedReserve = 3
if (last[i].allocatedReserve < alocatedReserve)
arr20Max.push(last[i])
}
last = arr20Max
}
if (name === 'allocatedReserveCompoundUnder2' || name === 'allocatedReserveCompoundUnder3') {
let arr20Max = []
for (let i = 0; i < last.length; i++) {
if (name === 'allocatedReserveCompoundUnder2')
alocatedReserve = 2
else
alocatedReserve = 3
if (last[i].allocatedReserve < alocatedReserve)
arr20Max.push(last[i])
}
last = arr20Max
}
// if (name === 'allocatedReservePerMonthUnder2' || name === 'allocatedReservePerMonthUnder3') {
// let arr20Max = []
// for (let i = 0; i < last.length; i++) {
// if (name === 'allocatedReservePerMonthUnder2')
// alocatedReserve = 2
// else
// alocatedReserve = 3
//
// if (last[i].allocatedReserve < alocatedReserve)
// arr20Max.push(last[i])
// }
//
// last = arr20Max
// }
//
// if (name === 'allocatedReserveCompoundUnder2' || name === 'allocatedReserveCompoundUnder3') {
// let arr20Max = []
// for (let i = 0; i < last.length; i++) {
// if (name === 'allocatedReserveCompoundUnder2')
// alocatedReserve = 2
// else
// alocatedReserve = 3
//
// if (last[i].allocatedReserve < alocatedReserve)
// arr20Max.push(last[i])
// }
//
// last = arr20Max
// }
//
let las = []
for (let i = 0; i < 1000; i++) {
......
......@@ -80,35 +80,35 @@ async function run(name, directory, timestamp) {
if (name === 'compound1000' || name === 'allocatedReserveCompoundUnder3' || name === 'allocatedReserveCompoundUnder2')
last = _.orderBy(arr2, ['CompoundPerMonthDrawDown'], ['desc']);
if (name === 'allocatedReservePerMonthUnder2' || name === 'allocatedReservePerMonthUnder3') {
let arr20Max = []
for (let i = 0; i < last.length; i++) {
if (name === 'allocatedReservePerMonthUnder2')
alocatedReserve = 2
else
alocatedReserve = 3
if (last[i].allocatedReserve < alocatedReserve)
arr20Max.push(last[i])
}
last = arr20Max
}
if (name === 'allocatedReserveCompoundUnder2' || name === 'allocatedReserveCompoundUnder3') {
let arr20Max = []
for (let i = 0; i < last.length; i++) {
if (name === 'allocatedReserveCompoundUnder2')
alocatedReserve = 2
else
alocatedReserve = 3
if (last[i].allocatedReserve < alocatedReserve)
arr20Max.push(last[i])
}
last = arr20Max
}
// if (name === 'allocatedReservePerMonthUnder2' || name === 'allocatedReservePerMonthUnder3') {
// let arr20Max = []
// for (let i = 0; i < last.length; i++) {
// if (name === 'allocatedReservePerMonthUnder2')
// alocatedReserve = 2
// else
// alocatedReserve = 3
//
// if (last[i].allocatedReserve < alocatedReserve)
// arr20Max.push(last[i])
// }
//
// last = arr20Max
// }
//
// if (name === 'allocatedReserveCompoundUnder2' || name === 'allocatedReserveCompoundUnder3') {
// let arr20Max = []
// for (let i = 0; i < last.length; i++) {
// if (name === 'allocatedReserveCompoundUnder2')
// alocatedReserve = 2
// else
// alocatedReserve = 3
//
// if (last[i].allocatedReserve < alocatedReserve)
// arr20Max.push(last[i])
// }
//
// last = arr20Max
// }
let las = []
......
......@@ -89,8 +89,8 @@ async function run() {
createfileADV('profitPerMonth1000', JSON.stringify(arr3, null, 2))
createfileADV('percentage1000', JSON.stringify(arrResrv200, null, 2))
createfileADV('compound1000', JSON.stringify(arr1000Compound, null, 2))
createfileADV('allocatedReservePerMonthUnder3', JSON.stringify(arr20MaxNew, null, 2))
createfileADV('allocatedReserveCompoundUnder3' , JSON.stringify(arrReservCompoundNew, null, 2))
// createfileADV('allocatedReservePerMonthUnder3', JSON.stringify(arr20MaxNew, null, 2))
// createfileADV('allocatedReserveCompoundUnder3' , JSON.stringify(arrReservCompoundNew, null, 2))
arr20Max=[]
for (let i = 0; i < arr2.length; i++) {
......@@ -115,8 +115,8 @@ async function run() {
arrReservCompoundNew.push(arrReservCompound[i])
}
createfileADV('allocatedReservePerMonthUnder2', JSON.stringify(arr20MaxNew, null, 2))
createfileADV('allocatedReserveCompoundUnder2' , JSON.stringify(arrReservCompoundNew, null, 2))
// createfileADV('allocatedReservePerMonthUnder2', JSON.stringify(arr20MaxNew, null, 2))
// createfileADV('allocatedReserveCompoundUnder2' , JSON.stringify(arrReservCompoundNew, null, 2))
......
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