Skip to content

[Feature] Custom calculated ratios — user-defined marker formulas #62

@elkimek

Description

@elkimek

Description

Allow users to define custom calculated markers with formulas like Marker A / Marker B. The result auto-computes whenever both source values exist for a date.

Currently, the three built-in calculated markers (BUN/Creatinine Ratio, Free Water Deficit, PhenoAge) are hardcoded. This would let users create their own without code changes.

Scope

  • Formula UI: pick two markers + operator (÷, ×, −, +) — or eventually free-form expressions
  • Dependency tracking: recalculate when source values change or are imported
  • Edge cases: missing values → null, division by zero → null, unit inference
  • Integration with import, export, manual entry (read-only values, editable formula)

Notes

This is a natural extension of the existing custom marker system. Lower priority — users can work around it by manually entering ratio values into the Calculated Ratios category.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions