euromod_linking.methods.lma_labour_alignment ============================================ .. py:module:: euromod_linking.methods.lma_labour_alignment .. autoapi-nested-parse:: lma_labour_alignment — align EUROMOD microdata to external labour-market targets and drive the LMA add-on. Works over any population cells the shock table defines, on full-population input, deterministically. Methodology is fixed here; scenarios can only set the declared params (period, tolerance_pct). Submodules ---------- .. toctree:: :maxdepth: 1 /autoapi/euromod_linking/methods/lma_labour_alignment/hierarchy/index /autoapi/euromod_linking/methods/lma_labour_alignment/imputation/index /autoapi/euromod_linking/methods/lma_labour_alignment/scoring/index /autoapi/euromod_linking/methods/lma_labour_alignment/states/index /autoapi/euromod_linking/methods/lma_labour_alignment/targets/index /autoapi/euromod_linking/methods/lma_labour_alignment/weights/index Attributes ---------- .. autoapisummary:: euromod_linking.methods.lma_labour_alignment.DEFAULT_FULLTIME_HOURS_PER_WEEK euromod_linking.methods.lma_labour_alignment.FULLTIME_HOURS_BOUNDS euromod_linking.methods.lma_labour_alignment.INJECTED euromod_linking.methods.lma_labour_alignment.MONTHS_PER_YEAR euromod_linking.methods.lma_labour_alignment.WEEKS_PER_MONTH Classes ------- .. autoapisummary:: euromod_linking.methods.lma_labour_alignment.LmaLabourAlignment Functions --------- .. autoapisummary:: euromod_linking.methods.lma_labour_alignment.fulltime_hours Package Contents ---------------- .. py:class:: LmaLabourAlignment See module docstring. Instances are stateless between calls. .. py:method:: apply(data: pandas.DataFrame, shocks: pandas.DataFrame, params: dict, ctx: euromod_linking.methods.base.MethodContext) -> euromod_linking.methods.base.MethodResult .. py:method:: baseline_transform(data: pandas.DataFrame, ctx: euromod_linking.methods.base.MethodContext) -> pandas.DataFrame Neutral LMA columns: identical for every shock table/period, so the baseline simulation is shared via the cache. The baseline runs WITH the LMA add-on active but lma=0 for everyone (no transitions), rather than without the add-on: both runs then go through an identical policy configuration, so the baseline/ counterfactual delta isolates the labour-market transitions and cannot pick up incidental differences from toggling the add-on itself. .. py:method:: check_dataset(columns, shocks: pandas.DataFrame) -> list[str] .. py:method:: preview(data: pandas.DataFrame, shocks: pandas.DataFrame, params: dict, ctx: euromod_linking.methods.base.MethodContext) -> dict What apply() would target, without fitting or aligning anything. Cheap enough to run at validation time, which is where a mis-sized shock has to be caught: after the run there is nothing left to do but discard two simulations. .. py:function:: fulltime_hours(country_code: str, system_name: str) -> tuple[float | None, str] The country's standard full-time week, from the model's own $lhw constant. Full-time differs by country (35 in FR, 38 in DK, 42 in AT), so the hardcoded 40 above would misstate entrants' earnings. Returns (hours, note); hours is None when $lhw is absent (IE, LV, NL) or implausible, and the default applies. .. py:data:: DEFAULT_FULLTIME_HOURS_PER_WEEK :value: 40.0 .. py:data:: FULLTIME_HOURS_BOUNDS :value: (10.0, 60.0) .. py:data:: INJECTED :value: ('lma', 'yem_a', 'yemmy_a', 'lhw_a') .. py:data:: MONTHS_PER_YEAR :value: 12 .. py:data:: WEEKS_PER_MONTH :value: 4.3333