-
The benchmark for
emissions_profile()
is changed fromtilt_sector
totilt_subsector
(@kalashsinghal #799). -
The benchmark for
emissions_profile_upstream()
is changed frominput_tilt_sector
toinput_tilt_subsector
(@kalashsinghal #799).
Developer-oriented changes:
example_products()
gains the columntilt_subsector()
(@kalashsinghal #803).
- Prune needless dependencies (ggplot2 and R/utils-tidy-eval.R) (#798).
Developer-oriented changes for code reuse:
-
check_crucial_names()
is now reusable via a standalone file (#796). -
export
epa_at_company_level()
andinsert_row_with_na_in_risk_category()
are now exported as internal (@kalashsinghal #795). -
categorize_risk()
is now exported as internal (@kalashsinghal #793).
Developer-oriented changes for code reuse:
spa_compute_profile_ranking()
andspa_compute_profile_ranking()
is now exported as internal, and documented along withepa_compute_profile_ranking()
under the topic?spa_compute_profile_ranking
(#791).
sector_profile()
now accounts for unmatchedtype
,sector
orsubsector
(@Tilmon #739). For example, given aclustered
matching one but not a secondtype
of scenario, when thescenarios
dataset has the two types, then the secondtype
and its correspondingscenario
are still present ingrouped_by
, and the mismatch is reflected correctly in thevalue
.
- The developer-oriented
example_data_factory()
is now exported so it can be reused elsewhere (#776).
- New
exclude()
helps remove columns and resulting duplicated rows (#772).
- New
join_to()
helps add a summary to a 'data.frame' or 'tilt_profile' (#771).
- New developer oriented (internal) function
document_tilt_profile()
(#770). This makes it easy to consistently document the output of any profile function.
-
Rename 'profile' to 'tilt_profile' to avoid clash the with
stats::profile()
(#769). Specifically:- The class 'profile' is now renamed to 'tilt_profile'.
- The constructor
profile()
is now renamed totilt_profile()
. - The predicate
is_profile()
is now renamed tois_tilt_profile()
.
-
New class 'profile', and related developer-oriented (internal) functions (#768):
- New constructor
tilt_profile()
. - New predicate
is_tilt_profile()
.
- New constructor
summarize_range()
is now a generic function with methods for both data frames and list of data frames (#764).
summarize_range()
now defaults tona.rm = FALSE
(#747). This is most common and conservative.
summarize_range()
gainsna.rm
and defaults to removing missing values (#743).
- The
sector*()
functions now preserve unmatched products (@AnneSchoenauer @Tilmon #738). This changes the structure of the output at company level, which now has four levels of risk_category: "high", "low", "medium", andNA
.
- The
emissions*()
functions now preserve unmatched products and missing benchmarks (@AnneSchoenauer @Tilmon #639). This changes the structure of the output at company level, which now has four levels ofrisk_category
: "high", "low", "medium", andNA
.
- The retired
xxtr()
functions now throw an error (#724) which more appropriately communicates to users the changes in #719.
- The datasets that moved to tiltToyData are now retired (#722). They have been deprecated for about 6 months now.
- Remove the article 'Handling long runtime' (#723). The tiltIndicator package is no longer suitable for it.
- The
xxtr*()
functions are now retired (#719). They have been deprecated for about 6 months now.
- Change license to GPLv3 (#674).
- The documentation of
emissions_profile()
is now reviewed (#693 @Tilmon).
-
Depend on R 4.1.0 (released on 2021-05-18) (#690).
-
The installation instructions now include r-universe (#685).
emissions_profile_any_compute_profile_ranking()
is now deprecated. This function is now internal (#669).
emissions_profile_any_compute_profile_ranking()
now handles special cases (#644 @kalashsinghal).
- The column
*isic_4digit
can now have values of any length (#630 @kalashsinghal).
- The percent deviation caused by
jitter*()
is now more even (#627).
- New helpers
summarize_range()
andjitter_range()
(#622, @AnneSchoenauer).
- All functions now use
companies_id
but still acceptcompany_id
with a warning (#621).
- All functions at product level now output the new column
profile_ranking
(#613, @AnneSchoenauer).
- In results at product level,
clustered
is no longerNA
whenrisk_category
isNA
(#614, @AnneSchoenauer, @kalashsinghal).
Get started now shows sector_profile*()
documentation (#619).
- Rename
emissions_profile_any_add_values_to_categorize
toemissions_profile_any_compute_profile_ranking
(#609). The old name is retired without deprecation since it had no users.
emissions_profile_any_add_values_to_categorize()
now relocates the new columns to the left.
emissions_profile*()
usesco2$values_to_categorize
if present (#605).
- New pre-processing helper
emissions_profile_any_add_values_to_categorize()
(#602).
- The values of
grouped_by
are now less surprising (see related principle) (#601). They now simply refer to the full name of the corresponding columns in the "co2" dataset (products or inputs) passed to theemissions_profile*()
functions. For example, passing a columnproducts$tilt_sector
now yields the value "tilt_sector" ingroup_by
-- which before got cropped to "tilt_sec".
- The usage of
*rowid
columns is now documented and is more rigorous (#516):- The name
rowid
is now reserved. If any input dataset uses it, the result is an error. - Each
*rowid
column now must be unique. Duplicated names now result in an error.
- The name
- All profile functions allow passing
*rowid
columns from input tables to the output at product level (#511).
- Rename pre- and post-processing helpers (#503).
- Rename indicators in public documentation (#496).
emissions_profile*()
now handles numeric values of*isic_4digit
(#494).
- Deprecate datasets. They all moved to tiltToyData with new names (#493).
- All
*_at_product_level()
and*_at_company_level()
are now deprecated (#491).
xctr(data, inputs)
is now deprecated in favor or the newemissions_profile_upstream()
(#481).
xctr(data, products)
is now deprecated in favor or the newemissions_profile()
(#481).
istr()
is now deprecated in favor of the newsector_profile_upstream()
(#480).
pstr()
is now deprecated in favor of the newsector_profile()
(#479).
- Results at company level now preserve unmatched companies (#466).
- The article "Handling a long runtime" now shows an enhanced approach (#450).
- In
pstr()
now warns if thecompanies
has any semicolon ';' insector
orsubsector
(#449).
- In
products
,activity_uuid_product_uuid
is now unique (#447).
xctr()
now outputs results at both levels (#443).
istr()
now outputs results at both levels (#442).
-
pstr()
now outputs results at both levels (#441). -
New
unnest_product()
andunnest_company()
help get results at product and company levels from nested outputs like the one ofpstr()
.
- Ensure all outputs have no duplicate (#438)
- XSTR no longer errors with duplicated scenarios (#437).
- For all indicators at product level, each company with some match outputs no
NA
, and with no match outputs 1 row withNA
s in all columns (exceptcompaneis_id
(#436).
- For all indicators at company level, each company with a match has 3
value
s that sum 1 and noNA
for each level ofgrouped_by
, and each company with no match has 1value
that isNA
in total (#434).
xstr_prepare_scenario()
with duplicated scenario data now throws an error (#431). This avoids running indicators with corrupt input data and alerts that the preparation must be fixed.
istr()
is now sensitive tolow_threshold
andhigh_threshold
(#420).
- New
xstr_scenarios
replacesistr_scenarios
andpstr_scenarios
(@kalashsinghal #413).
pstr_prepare_scenario()
is now namedxstr_prepare_scenario()
(#385).
pstr_polish_output_at_copmany_level()
is now namedxstr_polish_output_at_copmany_level()
(#383).
xstr_prune_companies()
now expects the columncompany_id
(#380).
- New helper
xstr_prune_companies()
to drop rows where product info is 'NA' & sector info is duplicated (#379).
istr_inputs
now includes columns required in the output (@kalashsinghal #376).
-
In XSTR
NA
s in reductions are no longer an error but handled specially (@lindadelacombaz #350). -
In ISTR sample data and code now use the new structure (@kalashsinghal #353).
-
In ISTR default thresholds are now the same as in XCTR (@lindadelacombaz #348).
- XXTR functions now stop if
companies
has 0-rows (#340).
- XSTR and XCTR functions now stop if
scenarios
orco2
has 0-row (#337, #338).
- In PSTR default thresholds are now the same as in XCTR (@lindadelacombaz #329).
- New
pstr_polish_output_at_company_level()
(#327)
- The article "Handling long runtime" is now updated based on the experience running
pstr*()
(#314).
- Each scenario
type
must have somesector
andsubsector
, else you an error (#311).
pstr_prepare_scenario()
now handles "weo" data correctly (@kalashsinghal #309).
- With
type
"ipr", for each company andgrouped_by
,value
sums 1 (#307).
- The column
grouped_by
now includes the scenario type (#306). This makes the columngrouped_by
contain all the information inscenarios
,year
, andtype
-- meaning that those columns could be removed to keep the output simpler, without loosing information.
-
pstr_at_product_level()
now output columns as in the google sheet template (#303). -
Each
company_id + grouped_by
now gets one low, medium & highrisk_category
(#278).
- In ISTR the old argument
scenario
is now namedscenarios
, consistently with PSTR (#299).
- In
xstr*()
,NA
s inreductions
now trigger an error (#298).
- In PSTR the example datasets are now updated (@kalashsinghal #287).
- Each company & benchmark now gets a unique risk_category (@Tilmon #286).
-
New article handling long runtime (#283)
-
pstr*()
gain argumentslow_threshold
andhigh_threshold
(@kalashsinghal #273). -
pstr*()
values are now expressed as proportion (@lindadelacombaz #274).
xctr_at_product_level()
now dropsNA
s from unmatched products (#267).
ictr*()
andpctr*()
are now retired (#264).
The data is now simpler:
-
ictr_companies
andpctr_companies
are now retired. Instead use the new datasetcompanies
. -
pctr_ecoinvent_co2
is now renamed toproducts
. -
ictr_inputs
is now renamed toinputs
.
- New
xctr*()
replaceictr*()
andpctr*()
(#256). The functionsictr*()
andpctr*()
are internal for backward compatibility but will be retired soon.
- ICTR and PCTR at product level no longer output needless columns (#251).
- In ICTR and PCTR the argument
low_threshold
now default to 1/3 andhigh_threshold
to 2/3 (#249).
- A company with 3 different products and varying footprints now gets correct value (@Tilmon #248).
- ICTR and PCTR now handle duplicated
co2
data (#230).
*ctr_at_product_level()
now outputsclustered
and*_uuid
(#242).
- In ICTR and PCTR example datasets are now updated (@kalashsinghal #237).
pctr_at_product_level()
now returns visibly (#239).- ICTR and PCTR now handle duplicated
companies
data (#230). - In ICTR & PCTR ranking benchmarks are now updated (@kalashsinghal #229).
- In ICTR & PCTR
high_threshold
is now computed correctly (@kalashsinghal #229).
-
All product-level functions now output the same three columns (#228, #227):
companies_id
grouped_by
risk_category
- Datasets from the same family are now documented together (#224).
-
All company-level functions now output the same four columns:
companies_id
grouped_by
risk_category
value
- In ICTR and PCTR the example datasets are now updated (@kalashsinghal #217).
-
All top level functions now output the same first four columns (#214):
companies_id
grouped_by
risk_category
value
ictr_at_product_level()
andpctr_at_product_level()
now output company data (#213).
- In PSTR use new data (@lindadelacombaz #196).
-
In both
ictr()
andpctr()
the first argument is now namedco2
. -
New internal-ish functions in the xctr family (#207).
- In PCTR, if a company matches no input, all shares are now
NA
(#205).
- In ICTR, if a company matches no input, all shares are now
NA
(@kalashsinghal #202).
- Even if companies has a *uuid absent in inputs/co2, all shares now sum 1 (@kalashsinghal #197).
- All indicators now output ungrouped data (#193)
-
All indicators now export a single and similar top-level interface (#189). The old functions are still available but are are now considered developer-oriented and therefore not visible on the website. The output is also more similar: The first column is always
id
, the second column is alwaystransition_risk
, and the following column(s) provide score(s). -
All indicators now output an id for each company and a score (#190).
- In ICTR the example data now reflects real data more closely (@kalashsinghal #170).
-
ictr_score_companies()
now errors ifinputs_co2
hasNA
s (@kalashsinghal #150). -
New article Get started (#152).
- Add istr mvp ( @Lyanneho #144).
BREAKING CHANGES
-
ictr_inputs
andictr_companies
loose non-crucial columns(@kalashsingal #117). -
pctr_ecoinvent_co2
andpctr_companies
loose non-crucial columns (#116).
BUG FIXES
-
ictr_score_companies()
andictr_score_companies()
now return three rows per company regardless the number of rows in the co2 data (#122). -
pctr_score_companies()
andictr_score_companies()
now return three rows per company (@kalashsinghal #111).
-
Document PCTR functions (@kalashsinghal, #104).
-
New ICTR functions and datasets (@kalashsinghal, #90).
- Add ICTR MVP (#90).
- The un-prefixed pstr datasets are now retired (#79).
- Remove
pstr_plot_company()
(#84). - The name of PSTR datasets now include the prefix "pstr_" (#74).
- The developer-oriented functions are now internal (#67).
- Remove internal article (#66).
- New
pctr_*()
family of functions and datasets (#60, #61).
- Add pctr (@Tilmon, #56)
-
FIX: The article pstr now shows the expected content (#52).
-
FIX:
mvp_path()
with nonexistent path now throws an error (#51).
-
Document the
pstr_*()
functions (@lindadelacombaz, #50) -
dev: Rename helper to
render_to_list()
(#43). -
dev: Prune needless helpers (#42).
-
dev: Rename data-files related to pstr (#41).
-
dev: Fix CODEOWNERS.
- dev: Rename data-files related to pstr so it's easier to express Linda's ownership (#41).
- dev: Use CODEOWNERS (#39).
-
In
pstr_at_company_level()
fix missing argumentcompanies
(#38). -
dev: Address R CMD Check about undefined global variables (#37).
- dev: Use new argument to
left_join()
.
- dev: Address dplyr warnings (#32).
-
New
pstr_*()
family for product sector transition risk. -
New
pstr_*()
family of PSTR functions. -
New article "Product sector transition risk" (@lindadelacombaz, #18, #22).