Optimizing Sequencing Resource Allocation"

knitr::opts_chunk$set(collapse = TRUE, comment = "#>",
                      fig.width = 7, fig.height = 4, dev = "png")

Why allocation matters

In genomic surveillance, the total number of sequences you can generate each week is fixed by lab capacity and budget. The question is not how many to sequence (phylosamp answers that), but how to distribute a fixed number across regions, institutions, and sample sources.

Poor allocation wastes resources. If you sequence proportionally to submissions (which is what most systems do by default), you over-represent regions that send more samples --- which are often the same regions that already have the highest sequencing rates.

The three objectives

survinger supports three optimization objectives:

Example

library(survinger)
data(sarscov2_surveillance)

design <- surv_design(
  data = sarscov2_surveillance$sequences,
  strata = ~ region,
  sequencing_rate = sarscov2_surveillance$population[c("region", "seq_rate")],
  population = sarscov2_surveillance$population,
  source_type = "source_type"
)

Optimize for minimum MSE

alloc_mse <- surv_optimize_allocation(design, "min_mse", total_capacity = 500)
print(alloc_mse)
plot(alloc_mse)

Compare all strategies

comparison <- surv_compare_allocations(design, total_capacity = 500)
print(comparison)

The table shows the trade-off: minimizing MSE may increase imbalance, while proportional allocation sacrifices detection power.

With minimum coverage constraints

alloc_floor <- surv_optimize_allocation(
  design, "min_mse", total_capacity = 500, min_per_stratum = 20
)
print(alloc_floor)

Setting min_per_stratum = 20 ensures every region gets at least 20 sequences, preventing any region from being invisible.

Choosing an objective

In practice, reviewing the surv_compare_allocations() output helps stakeholders understand the trade-offs and choose based on their mandate.



Try the survinger package in your browser

Any scripts or data that you put into this service are public.

survinger documentation built on April 27, 2026, 9:10 a.m.