Skip to content

superposition() never returns with auc.type = "AUClast" when a subject's tlast < tau (infinite loop at default n.tau = Inf) #580

Description

@billdenney

superposition(conc_obj, tau = 24, auc.type = "AUClast") with the default n.tau = Inf hangs indefinitely when any subject's last measurable concentration falls before tau (2 of 12 Theoph subjects): with AUClast-type extrapolation the tail contributes zeros, zeros persist across iterations, and the any(ret$conc %in% 0) guard in R/superposition.R resets the steady-state tolerance every iteration, so convergence is never declared. Reproduced on 0.12.1.9000. A finite n.tau avoids it.

Suggest either excluding structural zeros from the convergence check or capping iterations with an informative error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions