Repository navigation
Releases: dasmig/occupation-generator
Releases · dasmig/occupation-generator
Release list
v3.0.1
v3.0.0
v2.2.1
v2.2.0
v2.1.0
A child under school age is no longer a student. The API is unchanged.
Changed
- Under 6, a person is
inactive(outside the labour force) with no job and no education; from 6 to 14 they are astudent, as before. Before, everyone under 15 was a student, including newborns. - Only the status at ages 0-5 changes. No draw is added or removed, so other results and the known answers are the same. A status forced through the request is still honoured.
Details in PR #2.
v2.0.0
Makes a request the only way to call a getter.
Breaking
get_occupation(const occupation_request&)andget_occupation(request, seed);get_occupation({})draws a random country at the default age of 40,get_occupation({.country = "US"})fixes only the country.- The no-argument, country-only and seed-only overloads and instance
seed()/unseed()are removed. Data loading and layers stay on the instance.
See the documentation for the request type and examples.
v1.0.0
First release. Employment status, education and occupation by country, age and sex, built on dasmig-core 1.0.0.
Added
dasmig::ocg(dasmig/occupationgen.hpp):get_occupation(occupation_request), with(request, seed)and shorthands for a country, a seed or neither.occupation_request{country, age, person_sex, education, status}; every field is optional (age defaults to 40).occupation:country_code,person_sex,age,status(employed, unemployed, student, retired, inactive),education(four levels),job(key, label, ISCO-08 group and title, unit group, skill level, skills, gear, tags),to_json(),signature(),seed().- Seven layered tables (
status,inactivity,education,isco,shares,factors,occupations), extended withextend()/extend_from_string(table, ...); a directory layer applies to all its tables or none. lite(213 countries and territories, 95 jobs) andfull(213, 320 jobs) tiers;DASMIG_OCCUPATION_EMBEDcompileslitein (a 2 MB header).- Known-answer tests identical on clang 18 (libc++), gcc 14 (x86-64 with FMA, ARM64), Apple clang (ARM64), MSVC and Emscripten.
Data: read before relying on it
- Measured: employment status, education and the share of each ISCO-08 group by sex, and the age and education factors, from ILOSTAT (ILO, CC BY 4.0): the latest complete survey since 2010. Surveyed: status 139 countries, education 185, occupation shares 149; the others get a regional mean (
basis=region), which is a guess. - Curated: the 320-job catalogue (weights within an ISCO group, age limits, tags, skills, gear) and how the inactive split into students, retired and others (the same in every country).
- ILOSTAT only breaks occupation down by age into 15-24, 25-54, 55-64 and 65+. Age, education and sex are treated as independent given the group.
- Licences have not been reviewed (owner's decision).
See Data and Method for every column's source and the model's limits.