mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-09 04:50:59 +00:00
feat(environment): register env signals and wire weather into correlation discovery
Register the seven environmental-exposure signals through the signal registry as a new "environment" kind (correlation-eligible; off Coach/MCP/FHIR in v1), and fold their daily series into the correlation engine as lagged behaviour channels. Weather/daylight now pair against mood, sleep, and vitals through the existing FDR / effect-size / shrinkage gates, so a thin series degrades to absent rather than a spurious link. All env channels share one ENVIRONMENT family so two same-day fields never lag-correlate against each other.
This commit is contained in:
1 parent
76dc03ae7f
commit
cdee3e3efc
10 files changed
+265
-12
No files matched your search
@@ -52,6 +52,15 @@ const CHANNEL_LABEL_KEY: Record<string, string> = {
|
||||
HEART_RATE_VARIABILITY: "measurements.typeHeartRateVariability",
|
||||
RESTING_HEART_RATE: "measurements.typeRestingHeartRate",
|
||||
WEIGHT: "measurements.typeWeight",
|
||||
// v1.25 (W-ENV) — environmental-exposure channels, so a "daylight → mood"
|
||||
// relation reads with its descriptive label instead of the raw ENV_ key.
|
||||
ENV_TEMP_MEAN: "environment.fields.tempMean",
|
||||
ENV_TEMP_MIN: "environment.fields.tempMin",
|
||||
ENV_SUNSHINE: "environment.fields.sunshine",
|
||||
ENV_DAYLIGHT: "environment.fields.daylight",
|
||||
ENV_PRECIP: "environment.fields.precip",
|
||||
ENV_PRESSURE_MEAN: "environment.fields.pressureMean",
|
||||
ENV_PRESSURE_DELTA: "environment.fields.pressureDelta",
|
||||
};
|
||||
|
||||
/** Keep only the discovered pairs that involve the mood channel. */
|
||||
|
||||
Reference in new issue
Block a user