mle_bandit2arm: Maximum-likelihood estimation (MLE) of behavior of the...

Description Usage Arguments Value Examples

View source: R/estimate_bandit2arm.R

Description

This function runs the MLE technique to recover behavior from the simulated task data.

Usage

1
2
3
4
5
6
7
mle_bandit2arm(
  data = bandit2arm_data,
  param = list(init.x1, init.x2),
  fn = "mle.objectiveFunction",
  opt = "TRM",
  nRes = 5
)

Arguments

data

simulated two-armed bandit data

param

randomly generated initial parameters.

fn

objective function being minimized

opt

optimization algorithm used. Defaults to trust-region method (trm)

nRes

number of restarts. Defaults to 5.

Value

A list containing the sum log-likelihood, mle estimates of parameter 1 per subject, mle estimates of parameter 2 per subject, laplace values of parameter 1 per subject, laplace values of parameter 2 per subject.

Examples

1

psuthaharan/bandit2arm documentation built on Jan. 26, 2021, 1:36 a.m.