Skip to content

visreg2d #142

@turgeonmaxime

Description

@turgeonmaxime

We used to be able to directly input an singleEventCB object into visreg::visreg2d and get perspective plots. This is now broken because of commit bb18afd that saves the function call from fitSmoothHazard instead of from the underlying function (e.g. glm or gam).

Solution: We can build a wrapper around visreg::visreg2d, just like we did for visreg::visreg. In that wrapper, we can reshuffle the call to glm (it's stored in fit$lower_call) to avoid the errors downstream, just like we did for plot.singleEventCB:

casebase/R/plot_methods.R

Lines 576 to 578 in 3adaa02

# Switch back call slot
# otherwise we get an error from visreg
x$call <- x$lower_call

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions