Skip to contents

Visualize likelihood profiles from MLE and/or MCMC estimation.

Usage

plot_profile(
  obj,
  x,
  y = NULL,
  xlab = NULL,
  rescale = TRUE,
  facet = FALSE,
  transform = "none",
  points = FALSE,
  k = 5
)

Arguments

obj

A TMB model object.

x

A data.frame containing MLE profile from tmbprofile2.

y

A data.frame containing MCMC profile from get_mcmc_profile (optional).

xlab

A character string for x-axis label, default is the parameter name.

rescale

A logical indicating whether to rescale to the minimum negative log-likelihood value.

facet

A logical indicating whether to facet by likelihood components.

transform

A character specifying transformation ("none", "exp", or "plogis").

points

A logical indicating whether to show MCMC posterior samples as points.

k

An integer specifying the number of basis functions for GAM smoothing.

Value

a ggplot2 object.