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

Refactor chart plotting #64

Merged
merged 4 commits into from
Nov 28, 2024
Merged

Conversation

senier
Copy link
Contributor

@senier senier commented Nov 20, 2024

This PR is in preparation of the changes discussed in #63.

The chart plotting functions got refactored to remove code duplication and make plotting more flexible. Plots can now be done as lines, circles or histograms in any combination on the primary as well as the secondary axis (or both at once).

Plots should look exactly the same as before (this appears to be true for demo data as well as my real world data).

Additionally:

  • some typos fixed
  • allow exporting the demo database
  • allow setting the configuration to be used in the Makefile

Copy link
Owner

@treiher treiher left a comment

Choose a reason for hiding this comment

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

That's a good improvement to the code! I just have a few small remarks.

valens/cli.py Outdated Show resolved Hide resolved
valens/cli.py Outdated Show resolved Hide resolved
frontend/src/ui/common.rs Outdated Show resolved Hide resolved
frontend/src/ui/common.rs Outdated Show resolved Hide resolved
frontend/src/ui/common.rs Outdated Show resolved Hide resolved
@senier senier force-pushed the refactor_chart_plotting branch from 7cfbb02 to 3c3801f Compare November 23, 2024 14:23
@senier senier force-pushed the refactor_chart_plotting branch from 3c3801f to f9c9e85 Compare November 23, 2024 14:41
@senier senier force-pushed the refactor_chart_plotting branch 2 times, most recently from f51152e to 1385a66 Compare November 24, 2024 16:46
@senier senier force-pushed the refactor_chart_plotting branch 3 times, most recently from b0ead6c to 0971c15 Compare November 24, 2024 21:28
frontend/src/ui/page/body_fat.rs Outdated Show resolved Hide resolved
frontend/src/ui/common.rs Show resolved Hide resolved
Copy link
Owner

@treiher treiher left a comment

Choose a reason for hiding this comment

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

Apart from the small issue in the body fat chart, everything looks correct now. As soon as this is fixed, the PR can be merged.

@senier senier force-pushed the refactor_chart_plotting branch from 0971c15 to 7112fe2 Compare November 27, 2024 22:06
@senier senier requested a review from treiher November 27, 2024 22:10
@senier senier force-pushed the refactor_chart_plotting branch from 7112fe2 to c5a4a0b Compare November 28, 2024 20:25
@treiher treiher merged commit 6260db4 into treiher:main Nov 28, 2024
26 checks passed
@senier senier deleted the refactor_chart_plotting branch November 28, 2024 21:36
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.

2 participants