Giter Club home page Giter Club logo

Comments (6)

 avatar commented on May 24, 2024 1

I did a bug-fixing pass, I believe everything in the examples works right now.

from cvxportfolio.

sunilshah avatar sunilshah commented on May 24, 2024

@jonathanng

Fixes in your current fork (jonathanng/cvxportfolio) seem reasonable, yet the examples do not work:

(1) Need to fix keyword change in call to MarketSimulator in HelloWorld and SinglePeriodOptimization

(2) After the name change the, HelloWorld gives reasonable results, but SinglePeriodOptimization gives negative returns for most of the coarse search parameters. The results do not correspond to plots in the notebook in the repository ( or in the paper).

Thanks.

from cvxportfolio.

jonathanng avatar jonathanng commented on May 24, 2024

Try the examples in my branch. Those should work.

from cvxportfolio.

sunilshah avatar sunilshah commented on May 24, 2024

Hi @jonathanng,

Thanks for getting back.

I tried your master branch (https://github.com/jonathanng/cvxportfolio, latest commit). My earlier comments are about the examples and the code in that branch (using the latest available versions of python 3.6 and notebook on Homebrew).

HelloWorld errors out in call to MarketSimulator:


TypeError Traceback (most recent call last)
in ()
2 market_returns = returns,
3 costs = [tcost_model, hcost_model],
----> 4 cash_key = 'USDOLLAR'
5 )
6

TypeError: init() got an unexpected keyword argument 'market_returns'

Upon correcting the keyword to your March 2 commit, the notebook runs and gives reasonable results.

PortfolioSimulation.ipynb also needs the same correction. However, it generates results that are very different ( Active Risk at 19.3%) from those in the notebook on github.

SinglePeriodOptimization also generates very different results after the keyword correction. Most of the results of coarse search have very large negative excess returns.

Please re-run the examples. If you post the corrections in your branch I will be happy to test them out.

from cvxportfolio.

jpiter avatar jpiter commented on May 24, 2024

Can you please let me know where I can find fixed examples. It's been a year, so I assume the master branch must have been updated, but I still see the same error on MPOReturnsForecast with abstract methods weight_expr. TIA.

from cvxportfolio.

esvhd avatar esvhd commented on May 24, 2024

I did a bug-fixing pass, I believe everything in the examples works right now.

Hi @enzobusseti,

I'm still running into problems trying to instiantiate MPOReturnsForecast class as well after cloning and installing the latest master branch here. Is the fix here simply to create a dummy weight_expr() method for the class since it's not being used?

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-24-d1b92aa49092> in <module>
----> 1 returns_forecast = cp.MPOReturnsForecast(all_return_estimates)
      2 results_MPO={}

TypeError: Can't instantiate abstract class MPOReturnsForecast with abstract methods weight_expr

from cvxportfolio.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.