RMI-PACTA / r2dii.data

Datasets to Align Financial Markets with Climate Goals
https://rmi-pacta.github.io/r2dii.data
Creative Commons Zero v1.0 Universal
6 stars 6 forks source link

feat: individual `sector_classification` bridges gain `title` column describing what the code refers to #234

Closed jdhoffa closed 6 months ago

jdhoffa commented 3 years ago

This exists for all but the nace andisic classification bridges.

library(r2dii.data)
library(dplyr)
#> 
#> Attaching package: 'dplyr'
#> The following objects are masked from 'package:stats':
#> 
#>     filter, lag
#> The following objects are masked from 'package:base':
#> 
#>     intersect, setdiff, setequal, union

sic_classification %>% 
  select(description)
#> # A tibble: 256 x 1
#>    description                                                                  
#>    <chr>                                                                        
#>  1 private households, exterritorial organisations, representatives of foreign …
#>  2 private households, exterritorial organisations, representatives of foreign …
#>  3 growing of cereals and other crops n.e.c.                                    
#>  4 growing of fruit, nuts, beverage and spice crops                             
#>  5 farming  of cattle, sheep, goats, horses, asses, mules and hinnies;dairy far…
#>  6 growing of crops combined with farming of animals (mixed farming)            
#>  7 forestry and related services                                                
#>  8 logging and related services                                                 
#>  9 ocean and coastal fishing                                                    
#> 10 mining of coal and lignite                                                   
#> # … with 246 more rows

gics_classification %>% 
  select(description)
#> # A tibble: 263 x 1
#>    description                         
#>    <chr>                               
#>  1 oil & gas drilling                  
#>  2 oil & gas equipment & services      
#>  3 integrated oil & gas                
#>  4 oil & gas exploration & production  
#>  5 oil & gas refining & marketing      
#>  6 oil & gas storage & transportation  
#>  7 coal & consumable fuels             
#>  8 commodity chemicals                 
#>  9 diversified chemicals               
#> 10 fertilizers & agricultural chemicals
#> # … with 253 more rows

psic_classification %>% 
  select(original_code)
#> # A tibble: 1,271 x 1
#>    original_code                                                                
#>    <chr>                                                                        
#>  1 Growing of leguminous crops such as: mongo, string beans (sitao), pigeon pea…
#>  2 Growing of ground nuts                                                       
#>  3 Growing of oil seeds (except ground nuts) such as soya beans, sunflower and …
#>  4 Growing of  sorghum, wheat                                                   
#>  5 Growing of other cereals (except rice and corn), leguminous crops and oil se…
#>  6 Growing of paddy rice, lowland, irrigated                                    
#>  7 Growing of paddy rice, lowland, rainfed                                      
#>  8 Growing of paddy rice, upland/kaingin                                        
#>  9 Growing of corn, expcept young corn (vegetable)                              
#> 10 Growing of sugarcane including muscovado sugar-making in the farm            
#> # … with 1,261 more rows

naics_classification %>% 
  select(naics_title)
#> # A tibble: 1,057 x 1
#>    naics_title                                      
#>    <chr>                                            
#>  1 soybean farming                                  
#>  2 oilseed (except soybean) farming                 
#>  3 dry pea and bean farming                         
#>  4 wheat farming                                    
#>  5 corn farming                                     
#>  6 rice farming                                     
#>  7 oilseed and grain combination farming            
#>  8 all other grain farming                          
#>  9 potato farming                                   
#> 10 other vegetable (except potato) and melon farming
#> # … with 1,047 more rows

cnb_classification %>% 
  select(original_code)
#> # A tibble: 220 x 1
#>    original_code                                
#>    <chr>                                        
#>  1 ADMINISTRATIVE AND SUPPORT SERVICE ACTIVITIES
#>  2 ADMINISTRATIVE AND SUPPORT SERVICE ACTIVITIES
#>  3 ADMINISTRATIVE AND SUPPORT SERVICE ACTIVITIES
#>  4 ADMINISTRATIVE AND SUPPORT SERVICE ACTIVITIES
#>  5 ADMINISTRATIVE AND SUPPORT SERVICE ACTIVITIES
#>  6 AGRICULTURE                                  
#>  7 AGRICULTURE                                  
#>  8 AGRICULTURE                                  
#>  9 AGRICULTURE                                  
#> 10 AGRICULTURE                                  
#> # … with 210 more rows

nace_classification
#> # A tibble: 996 x 5
#>    original_code code  code_level sector       borderline
#>    <chr>         <chr>      <dbl> <chr>        <lgl>     
#>  1 A             A              1 not in scope FALSE     
#>  2 1             10             2 not in scope FALSE     
#>  3 1.1           110            3 not in scope FALSE     
#>  4 1.11          1110           4 not in scope FALSE     
#>  5 1.12          1120           4 not in scope FALSE     
#>  6 1.13          1130           4 not in scope FALSE     
#>  7 1.14          1140           4 not in scope FALSE     
#>  8 1.15          1150           4 not in scope FALSE     
#>  9 1.16          1160           4 not in scope FALSE     
#> 10 1.19          1190           4 not in scope FALSE     
#> # … with 986 more rows

isic_classification
#> # A tibble: 768 x 4
#>    code  code_level sector       borderline
#>    <chr>      <dbl> <chr>        <lgl>     
#>  1 A              1 not in scope FALSE     
#>  2 1              2 not in scope FALSE     
#>  3 11             3 not in scope FALSE     
#>  4 111            4 not in scope FALSE     
#>  5 112            4 not in scope FALSE     
#>  6 113            4 not in scope FALSE     
#>  7 114            4 not in scope FALSE     
#>  8 115            4 not in scope FALSE     
#>  9 116            4 not in scope FALSE     
#> 10 119            4 not in scope FALSE     
#> # … with 758 more rows

Created on 2021-06-10 by the reprex package (v2.0.0)

AB#10171

maurolepore commented 3 years ago

Maybe a good time to try unify the name of such column? The name "description" seems most informative to me.

jdhoffa commented 3 years ago

Agreed! I think we can also unify a couple other things about the classification bridges, including how we handle different levels.

This relates to #229

jdhoffa commented 7 months ago