Skip to content
This repository has been archived by the owner on Dec 14, 2023. It is now read-only.

Add sector order to create_interactive_report input #356

Merged
merged 6 commits into from
Dec 9, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion web_tool_script_3.R
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,11 @@ js_translations <- jsonlite::fromJSON(
txt = path(template_path, "data/translation/js_labels.json")
)

sector_order <- readr::read_csv(
path(template_path, "data/sector_order/sector_order.csv"),
maurolepore marked this conversation as resolved.
Show resolved Hide resolved
col_types = cols()
)

# Needed for testing only
shock <- shock_year # this should come directly from the stress test.. 2030 based on current discussions in CHPA2020 case
select_scenario_auto = scenario_auto
Expand Down Expand Up @@ -218,7 +223,8 @@ create_interactive_report(
ipr_results_stress_test = ipr_results_stress_test,
display_currency = display_currency,
currency_exchange_value = currency_exchange_value,
header_dictionary = header_dictionary
header_dictionary = header_dictionary,
sector_order = sector_order
Copy link
Contributor

@maurolepore maurolepore Dec 9, 2020

Choose a reason for hiding this comment

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

My suggestion above adds logic that you can't inject in a variable like sector_order, but you can inject it in a function sector_order().

Copy link
Contributor

Choose a reason for hiding this comment

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

Let me try something out. An example may be clearer than my words above.

)


Expand Down