-
Notifications
You must be signed in to change notification settings - Fork 0
add percent pacta sectors content values #103
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
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #103 +/- ##
========================================
- Coverage 0.80% 0.79% -0.02%
========================================
Files 25 25
Lines 1619 1644 +25
========================================
Hits 13 13
- Misses 1606 1631 +25 ☔ View full report in Codecov by Sentry. |
Noted and makes sense! |
|
|
|
|
||
| pacta_sectors_percent_total_value_equity <- | ||
| audit_file %>% | ||
| dplyr::filter(.data$valid_input == TRUE) %>% |
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.
😂
jdhoffa
left a comment
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.
Looks great!
In the current template's report text, the percentages of covered assets by value for Equity and Bonds should match the percentage values in the sector coverage by value pie charts. However, it is currently using
total_portfolio_percentage_equityandtotal_portfolio_percentage_equitywhich is the percent of Equity and Bonds within the total portfolio value.Since the desired values are not exported by
calculate_report_content_variables(), this PR adds those values to be exported. Additionally, it utilizes those values in the text of the integrated template. For templates typically used on Transition Monitor, those templates will need to be similarly updated in https://github.com/RMI-PACTA/templates.transition.monitorThe original change in the template text to use these newly desired values occurred in https://github.com/RMI-PACTA/templates.transition.monitor/pull/2 and then an incorrect fix to that occurred in https://github.com/RMI-PACTA/templates.transition.monitor/pull/18
@jdhoffa note that the percentages shown in the value pie charts are calculated within the JavaScript, therefore I had to calculate them separately to make it available for injection into the HTML text:
pacta.portfolio.report/inst/js/PieExploded2.js
Line 306 in 24221e7