Learn R Programming

utilityFunctionTools (version 0.1.0)

compute_measures_aux: Given a set of smooth and continuous functions, computes predefined and user-defined measures.

Description

Given a set of smooth and continuous functions, computes predefined and user-defined measures.

Usage

compute_measures_aux(
  x_grids,
  coeffs,
  ids,
  ndx = 20,
  deg = 6,
  measures = c("risk-arrow-pratt", "crainich-eeckhoudt", "denuit-eeckhoudt"),
  ...
)

Arguments

x_grids

a dataframe of vectors of x-values for a smooth and continuous function.

coeffs

a dataframe of coefficients for a smooth and continuous function for each participant.

ids

a list containing the IDs of the participants. If not given, a list with IDs from 1 to n_observations will be created.

ndx

number of intervals to partition the distance between the lowest and highest x-values of the utility points.

deg

degree of the B-spline basis. Determines the degree of the function to be estimated. If deg = 2, the estimated utility function will consist of quadratic functions.

measures

a vector of measures to be computed.

...

additional parameters for user-defined measures.

Value

A set of measurements.