Skip to content

Decide: discriminatory PLS group weighting — size-weighted (current) vs equal-per-group (McIntosh task-PLS) #27

Description

@eilidhmacnicol

Question

In discriminatory PLS, plsdo builds X as a 0/1 dummy design and z-scores Y, then forms xcorr = Xᵀ·Y / (n−1). This makes each group's row proportional to n_g × (group mean − grand mean) — i.e. size-weighted: larger groups contribute more to the SVD. McIntosh's task-PLS centres on group mean − grand mean with equal weight per group.

Decide whether to keep size-weighting (and document it) or switch to equal-per-group weighting to match the canonical McIntosh task-PLS.

When it matters

  • Balanced groups → the two are identical up to an overall scalar (a uniform row scaling doesn't change SVD directions). True at any n.
  • Divergence grows with the group-size ratio: roughly negligible <1.5×, noticeable on borderline loadings 1.5–3×, material >3× (the large group can dominate the LVs).
  • Absolute small n is a separate concern (bootstrap degeneracy guard), not this.
  • Correlational PLS is unaffected.

Before deciding (verify, don't assert)

The McIntosh side below comes from fast-model source summaries that have been unreliable; confirm at source first.

  1. Read rri_get_covcor.m / rri_task_mean.m line-by-line to confirm McIntosh's exact mean-centring and per-group weighting.
  2. Confirm plsdo's actual construction in pipeline.py (discriminatory branch) and io.build_design_matrix.
  3. Run both weightings on a real unbalanced discriminatory dataset and compare LVs / BSRs / significance — let execution drive the decision.

Options

  • A: Match McIntosh (equal-per-group / task-mean centring) for citability.
  • B: Keep size-weighting as a deliberate choice and document the divergence.

See .dev/superpowers/plans/mcintosh-alignment.md for the wider alignment plan.

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: lowNice-to-haveroadmapPlanned post-0.1 work, not blocking releasetype: questionUsage questions, clarification requests

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions