Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
forex
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
forex
Commits
211a6aeb
Commit
211a6aeb
authored
Dec 28, 2021
by
Ahmad Nemati
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
init
parent
1424731d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
ai.js
ai.js
+5
-2
generate.js
generate.js
+1
-1
No files found.
ai.js
View file @
211a6aeb
...
...
@@ -9,7 +9,7 @@ let base = 'base'
function
run
(
data
,
config
,
risk
,
pfTrade
,
riskFreeLevel
,
detail
)
{
let
type
=
config
.
type
+
'
param:
'
+
config
.
param
+
'
base:
'
+
config
.
base
+
'
target:
'
+
config
.
target
let
saveData
=
[]
let
needPrintData
=
shouldPrint
(
detail
,
data
[
0
].
signal
)
let
needPrintData
=
shouldPrint
(
detail
,
data
[
0
].
signal
+
'
&
'
+
type
)
// console.log(needPrintData)
let
commision
=
config
.
commision
...
...
@@ -85,7 +85,7 @@ let obj
obj
=
d
obj
.
maxReserve
=
maxReserve
obj
.
maxAllocatedMoney
=
maxAllocatedMoney
obj
.
maxLevel
=
max
Reserve
obj
.
maxLevel
=
max
Level
obj
.
step
=
step
obj
.
money
=
money
...
...
@@ -290,8 +290,11 @@ function calPer(entry, last) {
function
shouldPrint
(
details
,
type
)
{
for
(
let
i
=
0
;
i
<
details
.
length
;
i
++
)
{
if
(
details
[
i
]
===
type
)
return
true
}
return
false
}
...
...
generate.js
View file @
211a6aeb
...
...
@@ -21,7 +21,7 @@ run()
async
function
run
()
{
let
obj
=
{
sort
:
'
profitPerMonthDrawDown
'
,
alocatedReserve
:
3
,
alocatedReserveCompound
:
3
,
risk
:
1
,
start
:
2000
,
pfTrade
:
2
,
side
:
'
both
'
,
riskFreeLevel
:
100
,
onlyShortLong
:
false
}
let
detail
=
[
'
configs2.json-211021092159_O1_BNC_BTCUSD_Lp1_Y211020a - Copy_Mn.csv
'
,
'
configs2.json-211021092159_O1_BNC_BTCUSD_Lp1_Y211020a - Copy_Mn.csv
'
]
let
detail
=
[
'
configs2.json-211021092159_O1_BNC_BTCUSD_Lp1_Y211020a - Copy_Mn.csv
&zarib param:1.1 base:200 target:1
'
]
obj
.
detail
=
detail
let
all
=
[]
for
(
let
i
=
0
;
i
<
arr
.
length
;
i
++
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment