Skip to contents

Creates the business-level source-of-truth dataset used by BLADE projections. The output is written to _system/business-spine.parquet in the active fplida run directory. The companion _system/plida-blade-link.parquet is a synthetic fplida relationship file for PLIDA-to-BLADE exercises; the public BLADE correspondences are the DIL Appendix key products written by generate_blade(include_keys = TRUE).

Usage

generate_blade_business_spine(
  spine = NULL,
  seed = 42L,
  n_businesses = NULL,
  output_dir = NULL,
  format = c("parquet", "csv"),
  return_data = TRUE,
  overwrite = FALSE
)

Arguments

spine

Data.frame from generate_spine() or NULL. If NULL, selected person-spine columns are loaded from the active run directory.

seed

Integer. Random seed.

n_businesses

Integer or NULL. Optional business universe size. NULL derives a size from the person spine employment base.

output_dir

Character or NULL. Base output directory.

format

Character. "parquet" or "csv".

return_data

Logical. If TRUE, returns the business spine.

overwrite

Logical. If FALSE and a business spine already exists, it is reused.

Value

A data.frame when return_data = TRUE, otherwise an invisible metadata list.