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

Wire up company page #70

Merged
merged 16 commits into from
Nov 26, 2024
Merged

Wire up company page #70

merged 16 commits into from
Nov 26, 2024

Conversation

MonikaFu
Copy link
Contributor

@MonikaFu MonikaFu commented Nov 25, 2024

  • Make selectors work with the plots.
  • Implement error handling
  • Place two plots next to each other

NOTE: the data seems to be off. It shows no data for Automotive for techmix plot but then the power company names seem to be automotive names. Also, for techmix there exist only data for ownership weights for listed equity. I added two issues in workflow.pacta.dashboard: RMI-PACTA/workflow.pacta.dashboard#23 and RMI-PACTA/workflow.pacta.dashboard#22. But also we should look into the test data. Since the issues seem to be connected the data and not the workings of the dashboard, I consider this PR ready for review.

@MonikaFu MonikaFu changed the title Style techmix sector Wire up company page Nov 25, 2024
@MonikaFu MonikaFu marked this pull request as ready for review November 26, 2024 13:26
@MonikaFu MonikaFu requested a review from jdhoffa November 26, 2024 13:31
Comment on lines 2 to 16
{
"id": "Nissan Motor Co., Ltd.",
"id": "Hyundai Motor Co., Ltd.",
"ald_sector": "Automotive",
"technology": "Electric",
"plan_tech_share": 0.207746608894222,
"port_weight": 0.00761768898721195,
"scenario": "NZE 2050",
"plan_tech_share": 0.1927,
"port_weight": 0.1156,
"allocation": "portfolio_weight",
"scenario_source": "WEO2023",
"scenario": "APS",
"year": 2028,
"asset_class": "Listed Equity",
"ald_sector_translation": "Automotive",
"asset_class_translation": "Listed Equity",
"technology_translation": "LDV: Electric"
},
Copy link
Member

Choose a reason for hiding this comment

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

Hyundai appears to be accurately classed as an Automotive company in the data here?

@jdhoffa
Copy link
Member

jdhoffa commented Nov 26, 2024

@MonikaFu I believe the data is correct. In the (test) data, Hyundai is classed as both an Automotive Company and a Power company, when using the ownership_weight methodology. This is as expected, as it is likely that Hyundai owns both Car and Power producing assets (and ownership_weight allows for dual sectored companies, since we just roll up whatever the production is by owning share).

In portfolio_weight, that wouldn't be the case since we must select a specific sector to tie production to.

E.g.
Screenshot 2024-11-26 at 15 53 37

@jdhoffa
Copy link
Member

jdhoffa commented Nov 26, 2024

I am curious however why "Hyundai" isn't appearing in the company data plots for the Automotive sector? There is relevant data there, so I am surprised to not see a corresponding plot.

@MonikaFu
Copy link
Contributor Author

thanks @jdhoffa . Then indeed in this case it is not incorrect that automotive companies appear in power sector. It was strange to me to see them in power but not in automotive, that's why I thought it is a problem in the data. It still feels strange that they don't appear in the plots for automotive

@jdhoffa
Copy link
Member

jdhoffa commented Nov 26, 2024

thanks @jdhoffa . Then indeed in this case it is not incorrect that automotive companies appear in power sector. It was strange to me to see them in power but not in automotive, that's why I thought it is a problem in the data. It still feels strange that they don't appear in the plots for automotive

Data not appearing in the plots for Automotive feels like a problem that should be tackled in this PR actually! Or at least assessed to understand why they aren't showing up

@MonikaFu
Copy link
Contributor Author

@jdhoffa you are right, I was confused because of the data for Auto showing in Power. I somewhat assumed the data must be wrong. After closer inspection I found a bug in my implementation. I fixed it and added a check to prevent it in the future.

@MonikaFu MonikaFu merged commit 1c85d2a into main Nov 26, 2024
4 of 5 checks passed
@MonikaFu MonikaFu deleted the wire-up-company-page branch November 26, 2024 18:11
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