point_estimates function

Compute point estimates

Compute point estimates

This function computes the point estimates of an RprobitB_fit. Per default, the mean of the Gibbs samples is used as a point estimate. However, any statistic that computes a single numeric value out of a vector of Gibbs samples can be specified for FUN.

point_estimates(x, FUN = mean)

Arguments

  • x: An object of class RprobitB_fit.
  • FUN: A function that computes a single numeric value out of a vector of numeric values.

Returns

An object of class RprobitB_parameter.

Examples

data <- simulate_choices(form = choice ~ covariate, N = 10, T = 10, J = 2) model <- fit_model(data) point_estimates(model) point_estimates(model, FUN = median)