skfolio / skfolio

Python library for portfolio optimization built on top of scikit-learn
https://skfolio.org
BSD 3-Clause "New" or "Revised" License
1.01k stars 76 forks source link

[ENH] Effective number of assets #17

Closed CarloNicolini closed 6 months ago

CarloNicolini commented 6 months ago

Reference Issues/PRs

Issue #13 Implement effective number of assets

What does this implement/fix? Explain your changes.

The measure of portfolio concentration called effective number of assets. However I need to discuss how to embed this calculation in the portfolio.summary as it requires the asset weights, not the portfolio returns.

Does your contribution introduce a new dependency? If yes, which oneNo

What should a reviewer concentrate their feedback on?

The reviewer should indicate how to include this metric in the set of already existing metrics, given that it requires a different argument from simple portfolio returns.

Did you add any tests for the change?

No

For all contributions
codecov[bot] commented 6 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (60cd559) 99.14% compared to head (ddd5c26) 99.14%. Report is 13 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #17 +/- ## ======================================= Coverage 99.14% 99.14% ======================================= Files 35 35 Lines 2584 2584 ======================================= Hits 2562 2562 Misses 22 22 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.