Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Benchmark cleanup #2734

Merged
merged 3 commits into from
Jul 16, 2020
Merged

Benchmark cleanup #2734

merged 3 commits into from
Jul 16, 2020

Conversation

richafrank
Copy link
Member

Test is to ensure we're not broken as described in #2627 (comment)

@coveralls
Copy link

Coverage Status

Coverage remained the same at 88.21% when pulling bc9e754 on benchmark-cleanup into b661d07 on master.

def test_sharpe_value_when_benchmark_null(self):
# Sharpe is displayed as '0.0' instead of np.nan
null_returns = factory.create_returns_from_list(
[0.0]*251,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why 251? Aren't there 252 trading days?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't investigate further, but seems like not on NYSE in 2006. This came from trading_calendar.sessions_in_range(...).

@gerrymanoim
Copy link
Contributor

Small question, but LGTM

@richafrank richafrank merged commit ae9b8bc into master Jul 16, 2020
@richafrank richafrank deleted the benchmark-cleanup branch July 16, 2020 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants