Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
A
alpha-mind
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
Dr.李
alpha-mind
Commits
9dac0aeb
Commit
9dac0aeb
authored
Nov 10, 2018
by
Dr.李
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed bug for new cvxpy version
parent
c730cd46
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
2 deletions
+1
-2
linearbuilder.py
alphamind/portfolio/linearbuilder.py
+0
-1
meanvariancebuilder.py
alphamind/portfolio/meanvariancebuilder.py
+1
-1
No files found.
alphamind/portfolio/linearbuilder.py
View file @
9dac0aeb
...
...
@@ -91,7 +91,6 @@ def linear_builder(er: np.ndarray,
elif
method
.
lower
()
==
'ecos'
:
from
cvxpy
import
Problem
from
cvxpy
import
Variable
from
cvxpy
import
multiply
from
cvxpy
import
norm1
from
cvxpy
import
Minimize
...
...
alphamind/portfolio/meanvariancebuilder.py
View file @
9dac0aeb
...
...
@@ -74,7 +74,7 @@ def mean_variance_builder(er: np.ndarray,
prob
.
solve
(
solver
=
'ECOS'
,
feastol
=
1e-9
,
abstol
=
1e-9
,
reltol
=
1e-9
)
if
prob
.
status
==
'optimal'
or
prob
.
status
==
'optimal_inaccurate'
:
return
'optimal'
,
prob
.
value
,
np
.
array
(
w
.
value
)
+
bm
return
'optimal'
,
prob
.
value
,
np
.
array
(
w
.
value
)
.
flatten
()
+
bm
else
:
raise
PortfolioBuilderException
(
prob
.
status
)
else
:
...
...
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