BSTVCUser Guide
Desktop website ↗Download software

Continuous: global HALE

Follow a log-Gaussian analysis of health-adjusted life expectancy across 177 map units and 21 years.

Download this caseGo to the workflow ↓

Know the data

The source case combines global health, socioeconomic, environmental, and behavioral indicators for 2000–2020. The supplied map contains 177 unique spatial identifiers; the CSV contains 3,717 unique location–year records (177 × 21). Its spatial IDs match the map. Sources described in the manual include GBD, GIOVANNI, the World Bank, and air-quality data.

File / fieldMeaning
TestData_Continuous.csvOriginal panel table; no wide-to-long conversion required
TestMap_Continuous.*Complete world map component set
ISO_A3Shared map and panel identifier; case sensitive
Year2000 through 2020
HALEHealth-adjusted life expectancy, the response
Y3, NE3, NE7, HB2, HB6, PM2.5Six predictors in the introductory model

The source dictionary identifies Y3 as maternal mortality, NE3 as NDVI, HB2 as high body-mass index, and HB6 as vitamin A deficiency. PM2.5 is an air-pollution indicator. Neither source manual defines NE7, so this guide retains its field code without assigning a name or unit. Several source unit labels are inconsistent, so do not infer measurement units or transformations from those labels alone.

Field dictionary for both HALE models

The Chinese manual provides a broader dictionary for the optional 12-predictor prediction example. The table below brings those definitions into the English guide alongside the six-predictor introductory model. Descriptions and source attributions follow the teaching manual; they are not an independent audit of the original databases.

FieldDescription in the source manualSource attributionUse
HALEHealth-adjusted life expectancyGBDOutcome in both models
Y3Maternal mortality indicatorWorld BankIntroductory and expanded models
NE3Normalized Difference Vegetation Index (NDVI)GIOVANNIIntroductory and expanded models
NE7Field code retained as suppliedNot defined in either source manualIntroductory model only
HB2High body-mass index indicatorGBDIntroductory and expanded models
HB6Vitamin A deficiency indicatorGBDIntroductory and expanded models
PM2.5Annual population-weighted PM2.5 indicatorAir-quality data cited in the manualIntroductory and expanded models
HB1High alcohol-use indicatorGBDExpanded model only
NE2High-temperature indicatorGBDExpanded model only
SE3Female employment-to-population ratio, ages 15 and olderWorld BankExpanded model only
SE5Urban population shareWorld BankExpanded model only
SE6Gross national income per personWorld BankExpanded model only
SE7Current health expenditure as a share of GDPWorld BankExpanded model only
SE9Physicians per 1,000 peopleGBD, as attributed in the source tableExpanded model only

HALE is described in years. Several other unit labels in the source table are inconsistent with their descriptions, and indicator codes do not establish whether values are raw measurements, shares, or transformed estimates. Verify the original data documentation before interpreting a one-unit change or publishing a measurement unit. NE7 is retained as a code without an inferred name or unit.

The missingness figures in the introductory walkthrough are computed from the supplied CSV. Use its actual field properties for analysis; source-table percentages may describe a different subset or rounding convention. For the expanded model, inspect missingness in all 12 selected predictors before fitting.

1. Import and validate

  1. Open Data Input and use the modeling table Browse control to select TestData_Continuous.csv.
  2. In the map Browse control, select the complete TestMap_Continuous shapefile component set.
  3. Leave the custom matrix input empty for the default neighborhood.
  4. Select Load and Validate Input.
  5. Review Data Table field properties, types, missing-value ratios, and raw preview. Then review Map field properties and the boundary preview.
Continuous case: imported table and field properties.
Continuous case: imported table and field properties. Click to enlarge.
Continuous case: map attributes and geographic preview.
Continuous case: map attributes and geographic preview. Click to enlarge.

2. Check spatial order

  1. Open Data Check and select the BSTVC spatiotemporal panel check mode.
  2. Set Time Field to Year and Space Field to ISO_A3.
  3. Select Run Check and read the log. Confirm the full set of map identifiers has matched.
  4. If the application reports automatic rearrangement, export the checked table for your records and use Checked Data during modeling. If it reports an already aligned order, use Raw Data.

The original table is organized by location across years. At each time point, the modeling order must match the map order. For example, the supplied map begins FJI, TZA, ESH, CAN, USA. Let Data Check align the input rather than manually sorting identifiers alphabetically.

Continuous case: the Data Check log reports automatic rearrangement.
Continuous case: the Data Check log reports automatic rearrangement. Click to enlarge.

3. Configure and run the model

ParameterChoose
Response Variable YHALE
Explanatory Variables XY3, NE3, NE7, HB2, HB6, PM2.5
Response TypeContinuous (log-Gaussian)
Time FieldYear
Space FieldISO_A3
Data SourceRaw Data if already aligned; Checked Data if rearranged
Standardize X VariablesYes for the demonstrated comparisons
Spatial weight matrixDefault QUEEN-B
Threads6 as the starting setting
Continuous case: the six-predictor model settings in the English interface.
Continuous case: the six-predictor model settings in the English interface. Click to enlarge.
  1. Open BSTVC modeling and enter the settings listed above.
  2. Recheck the response family, time field, spatial field, and Data Source. Do not substitute IDs or time for explanatory variables.
  3. Select Run Model once and wait for the progress message to finish.
  4. When the result table appears, select Download All Tables. Save the workbook as HALE_all_result.xlsx in your case output folder.
  5. Keep the checked input table, map, chosen variables, neighborhood, thread setting, software version, and any error log with that workbook.
Continuous case: completed model results and workbook download controls.
Continuous case: completed model results and workbook download controls. Click to enlarge.

4. Read coefficients and contribution

Open model.evaluation first to inspect the completed model and diagnostic measures. Use time.coefficients to examine temporal variation, space.coefficients for geographic variation, and STVPI for model-based contribution with uncertainty.

Display 95% and 50% credible intervals alongside means. A colored spatial coefficient map is a map of a modeled association; it is not a map of causal effects. Read the coefficient-scale guidance before comparing directions or magnitudes.

Source example: temporal coefficients with 95% and 50% uncertainty bands.
Source example: temporal coefficients with 95% and 50% uncertainty bands. Click to enlarge.
Source example: spatial coefficient maps for the six-predictor continuous model.
Source example: spatial coefficient maps for the six-predictor continuous model. Click to enlarge.
Source example: spatiotemporal contribution estimates and uncertainty.
Source example: spatiotemporal contribution estimates and uncertainty. Click to enlarge.

5. Inspect prediction on the response scale

In local.prediction, y denotes the observed outcome, predict_y the response-scale prediction, and fill_y an outcome field with missing values filled. Continuous model output also contains log-scale summaries. The source workflow already back-transforms the columns with the predict_ prefix: do not exponentiate them again.

Compare observed and predicted values only where both exist. RMSE summarizes error in the response units; R² is relative to a mean-only reference and can be negative. Agreement on the fitted training data is descriptive performance, not independent validation. Use a suitable held-out design for claims about forecasting.

Historical 12-predictor HALE example: observed versus predicted outcomes.
Historical 12-predictor HALE example: observed versus predicted outcomes. Click to enlarge.
Historical 12-predictor HALE example: spatial predictions at selected years.
Historical 12-predictor HALE example: spatial predictions at selected years. Click to enlarge.

6. Export and continue

You should now have a checked panel, a saved settings record, and a workbook with the six result sections. For customized figures, follow R visualization and select the continuous case configuration. For deeper interpretation, use Understand results. Next, try the binary case to learn monthly wide-table conversion.