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

Display daily returns as bar chart with color=red for negative return… #3850

Merged

Conversation

LarsKarbach
Copy link
Contributor

…s and color=green for positive return

Description

The displayed daily return as given by the dret_chart command is implemented as a connected line chart. I think a bar chart is more visually appealing. I've gone further and added red/green color for returns below/above zero. See example:

Before:
Daily_return_old

After:
daily_return_new

@reviewpad reviewpad bot added the feat XS Extra small feature label Jan 1, 2023
@jmaslek
Copy link
Collaborator

jmaslek commented Jan 1, 2023

This definitely looks a lot nicer!

One question, instead of using red/green, can we use the custom theme files?

They are:

from openbb_terminal.config_terminal import theme

Then it is theme.up_color or theme.down_color instead of red/green

…gative returns and color=theme.up_color for positive return
@LarsKarbach
Copy link
Contributor Author

Of course, fixed it.

@jmaslek
Copy link
Collaborator

jmaslek commented Jan 3, 2023

Nice! The linter is now yelling. Running black ./ should fix the file and make it happy.

@jmaslek jmaslek merged commit ec41ab8 into OpenBB-finance:main Jan 3, 2023
@LarsKarbach LarsKarbach deleted the feature/prettify_daily_returns branch January 4, 2023 07:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat XS Extra small feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants