-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Allow users to provide extra rows in the top table #445
Conversation
@@ -81,7 +81,7 @@ def create_full_tear_sheet(returns, | |||
factor_returns=None, | |||
factor_loadings=None, | |||
pos_in_dollars=True, | |||
return_fig=False): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is that right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think so, for some reason we were accepting this argument but it wasn't being used anymore. return_fig is only used for the create_tear_sheet functions that produce one figure with multiple plots, like the returns tear sheet (the full tear sheet produces a bunch of figures). I am surprised this got by flake8 in the past.
Great feature. Is this off of recent master? |
Yeah off recent master. I will re-run tests once Travis starts passing on master, I think @vikram-narayan is working on that. |
Cool! I'm curious - what problem is this solving for the pyfolio user? |
@joshpayne we can use this internally to print metadata (code name, revision, etc.) about the algos within the tear sheet. Users can print their name, etc in here if they want to show this tear sheet to people. It also formats the dates at the top using the same function, whereas before they were just strings tacked on. |
This allows users to pass in extra rows (as a
dict
orOrderedDict
) to display in the perf_stats table. They can passheader_rows
tocreate_full_tear_sheet
,create_simple_tear_sheet
,create_returns_tear_sheet
,show_perf_stats
, andprint_table
. HTML will be generated and injected into the top of the table. Also puts the dates/ranges here, below the rows that the user passes.Also clean up a few random doc strings.
Examples: