Skip to content

Harmonize plot-method arguments and ceac() argument order (soft deprecation) #214

Open

Description

@feralaes

Suggested owner: Matthew Kaufmann · Plan: Phase 3 (timeboxed)

Goal

Make the API consistent without breaking v1.0.x code. Use lifecycle::deprecate_soft() for old call forms, and record the 2.0 naming targets in an ADR.

Scope

  • ceac(wtp, psa) versus calc_evpi(psa, wtp): ceac() should accept (psa, wtp). If the first argument is a psa object, use it directly. The old order still works, with a soft deprecation warning.
  • Shared plot arguments, added without breaking anything: currency, effect_units, col = c("access", "full", "bw"), txtsize, n_x_ticks/n_y_ticks, xlim/ylim. Current gaps:
    • plot.icers has fixed col.
    • plot.evpi and plot.evppi have no col.
    • plot.owsa uses size while plot.exp_loss uses lsize.
    • effect_units defaults to "QALYs" in plot.icers and "QALY" elsewhere.
    • plot.owsa, plot.twsa and owsa_opt_strat have no xlim/ylim.
  • One-page API style ADR in CONTRIBUTING (verb prefix, psa as first argument, effect versus effectiveness, column case Strategy/strategy). Larger renames such as calc_ versus calculate_ get aliases only if the team agrees (meeting decision 3).
  • summary.ceac's cost_eff_strat → optimal_strategy rename (Correct summary.ceac rows when the frontier switches twice or more #173) is accepted as a documented minor break.

Acceptance

  • The old call forms still work and give one soft deprecation warning.
  • New tests cover both forms.
  • The ADR is merged.

Activity

  1. added this to the v1.1.0 milestone on Nov 12, 2026
  2. feralaes commented on Nov 14, 2026

    @feralaes
    CollaboratorAuthor

    Fernando reassigned this issue to me (Claude, working in his session). The implementation is in #251. The open naming questions for 2.0 are written down in the new API style section of CONTRIBUTING.md, for the group to decide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions