-
Notifications
You must be signed in to change notification settings - Fork 0
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
Renaming output columns #118
Comments
@AnneSchoenauer, sounds great. I've been looking forward to this. Note the new names are use "emissions" in plural. Here is a record of the rename in tiltIndicator: https://2degreesinvesting.github.io/tiltIndicator/reference/rename.html We already use the new names in tiltIndicator, in tiltToyData, and in the new API of tiltIndicatorAfter but in tiltIndicatorAfter we still use the old names in a bunch of datasets and output columns (as you highlight here). Note that the change can break existing code if we simply renames one thing to other. If we want to make the change in a backward compatible way to avoid disrupting other team-members, then we need to go through a more gentle deprecation process. For example, the output table could have the deprecated old name AND also the new name for some time, then after a few weeks or months we retire the deprecated name and leave only the new one. There are more elegant ways to do that but this would be the simplest.
|
@AnneSchoenauer I can see that you removed
@AnneSchoenauer What does |
The suffix is removed as @Tilmon and I decided that strictly speaking the variable is not a risk variable anymore but a profile variable. This change is a result of changing PCTR/ICTR/PSTR/ISTR to emission profiles and sector profiles. sert means sector emission reduction targets. It is quite long that's why we called it sert. Do you want us to come up with a name that is more meaningful than sert but not too long as sector emission reduction targets? Please leave the function's name as it is. It is just that the profile_ranking in the sector profile is super similiar methodological wise than the profile_ranking of the emission profile. However, sert makes more sense in the output files though. |
@kalashsinghal could you when you implement this please use Mauro's suggestions on backward compatibility here |
@kalashsinghal and I discussed backward compatibility and we think a more elegant solution is this:
We plan to What do you think? |
Yes, this is great! |
Great. Then we plan for Kalash to draft a PR then I help review it. |
@AnneSchoenauer I can rename it to "sert", however it would make more sense to the user if the column name has words instead of abbreviations. Please let me know of your final decision! Thanks! |
Good point. @Tilmon what do you think about this? A different name could be |
We start from "sector emissions reduction targets" I think the name of the function that produces the column adds useful context. I think of it this way: sector_profile <- profile_sector(...)
sector_profile$sector_emissions_reduction_targets Here we see the word "sector" is a bit redundant. If we drop it we get this sector_profile$emissions_reduction_targets If that's still too long maybe |
@maurolepore super valuable information - thanks! @Tilmon I would prefer |
Hi @maurolepore and @AnneSchoenauer , I'm fine with |
Can we please rename the following columns for the output file. I assume this is something that should change in the tiltIndicatorAfter package? Is this correct? However, @maurolepore I think the function names already changed correct? So it is just to make sure that the output tables have the right names.
I am referring to these output tables here, which @SKruthoff gave Tilman and me on the 22nd of December.
Emission profile product level:
Renaming
PCTR_risk_category
inemission_profile
.Emission profile company level:
Renaming
PCTR_risk_category
inemission_profile
.Renaming
PCTR_share
inemission_profile_share
.Emission profile upstream product level (please note this was an empty file but I assume the following renaming):
Rename 'ISTR_risk_category' into 'emission_usptream_profile'
Emission profile upstream company level:
Rename 'ISTR_share' into 'emission_usptream_profile_share'
Rename 'ISTR_risk_category' into 'emission_usptream_profile'
Sector profile product level
Rename 'PSTR_risk_category' into 'sector_profile'
Rename 'sector' and 'subsector' to 'sector_scenario' and 'subsector_scenario'
Rename 'profile_ranking' into 'sert'
Sector profile company level
Rename 'PSTR_risk_category' into 'sector_profile'
Rename 'PSTR_share' into 'sector_profile_share'
Sector profile upstream product level
Rename 'ISTR_risk_category' into 'sector_profile_upstream'
Sector profile upstream company level
Rename 'ISTR_risk_category' into 'sector_profile_upstream'
Rename 'ISTR_share' into 'sector_profile_upstream_share
The text was updated successfully, but these errors were encountered: