The DIGCLASS
R package aims to make translation between occupational social classes easy and comprehensive. It facilitates the translation of the International Standard Classification of Occupations (ISCO) from 1968, 1988 and 2008 to a wide range of social class schemes.
This package is a work in progress and has implemented currently these translations:
-
ISCO68
- ISCO68 to ISCO88
- ISCO68 to ISCO08
- ISCO68 to SIOPS
- ISCO68 to ISEI
- ISCO68 to EGP11/EGP7/EGP5/EGP3
- ISCO68 to EGP11-MP
-
ISCO88
- ISCO88 to ISEI
- ISCO88 to SIOPS
- ISCO88 to IPICS
- ISCO88 to MPS88
- ISCO88 to EGP11/EGP7/EGP5
- ISCO88 to EGP11-MP
- ISCO88 to OESCH16/OESCH8/OESCH5
- ISCO88 to ISCO88COM
- ISCO88 to ISCO08
- ISCO88 to ISCO68
- ISCO88 to ORDC
- ISCO88COM to ESEC - ISCO88COM must be 3 digits
- ISCO88COM to ESEC-MP - ISCO88COM must be 3 digits
- ISCO88COM to MSEC - ISCO88COM must be 3 digits
- ISCO88COM to WRIGHT
-
ISCO08
- ISCO08 to ISCO88
- ISCO08 to ISEI
- ISCO08 to SIOPS
- ISCO08 to Microclasses
- ISCO08 to IPICS
- ISCO08 to OESCH16/OESCH8/OESCH5
- ISCO08 to ESEC - ISCO08 must be 3 digits
- ISCO08 to ESEC - ISCO08 must be 2 digits
- ISCO08 to ESEC-MP - ISCO08 must be 3 digits
- ISCO08 to MSEC - ISCO08 must be 3 digits
- ISCO08 to ESEG - ISCO08 must be 2 digits
-
ESCO
- ESCO to ISCO08
-
Extras
- Translation between major/submajor/minor/unit groups for ISCO68, ISCO88 and ISCO08
- Repair ISCO variables
Installation
You can install the development version of DIGCLASS from GitLab with:
# install.packages("devtools")
devtools::install_git("https://code.europa.eu/digclass/digclass.git")
Example
Here’s an example of translating ISCO68 to ISEI and EGP class schemas:
library(DIGCLASS)
library(dplyr)
# Internal data for the European Social Survey round 6
# containing different ISCO variables
ess %>%
transmute(
isco68,
isei = isco68_to_isei(isco68),
egp = isco68_to_egp(isco68, self_employed, emplno),
egp_labels = isco68_to_egp(isco68, self_employed, emplno, label = TRUE)
)
#> # A tibble: 48,285 × 4
#> isco68 isei egp egp_labels
#> <chr> <chr> <chr> <chr>
#> 1 5890 35 6 'IVb: Self-employed with no employees'
#> 2 2120 67 2 'II: Lower Controllers'
#> 3 7200 34 8 'VI: Skilled Worker'
#> 4 9310 32 8 'VI: Skilled Worker'
#> 5 6220 16 10 'VIIb: Farm Labor'
#> 6 6220 16 10 'VIIb: Farm Labor'
#> 7 9595 24 9 'VIIa: Unskilled Worker'
#> 8 6000 46 11 'IVc: Self-employed Farmer'
#> 9 6000 46 11 'IVc: Self-employed Farmer'
#> 10 6220 16 10 'VIIb: Farm Labor'
#> # ℹ 48,275 more rows
The nomenclature of the function is {origin}_to_{destination}
where origin
is the origin class schema and destination
is the destination class schema. The usual workflow is for you to type, for example isco
and then hit TAB
to get auto-completion on all possible translations.
For those class schemas that have labels, the label
argument returns the labels instead of the class codes.
Steps to add a new translation
Add two csv files respectively in
data-raw/social_classes/labels/
anddata-raw/social_classes/translation/
containing the labels and translation for the two schemas.Run the script
data-raw/social_classes.R
(with the root directory indata-raw/
)Add a new function inside
R/
with the convention{origin}_to_{destination}()
where origin and destination are the class schemas we’re translating. Please have a look at other translation to recycle common functions to do translations.Add proper documentation to the function
Other R packages
This package has benefitted greatly from other open source packages that already pave the way for translation between social class schemas. In particular, we’ve learned a lot and borrowed code from all of these packages:
- ISCOGEN: Stata package
- SocialPosition: R package
- occupar: R package
Funding
This project has been funded through the European Commission’s JRC Centre for Advanced Studies and the project Social Classes in the Digital Age (DIGCLASS): https://joint-research-centre.ec.europa.eu/tools-and-laboratories/centre-advanced-studies/digclass_en