bandwidth_optimal: Cross-validation estimate of bandwidth for known...

Description Usage Arguments Value

Description

Finds the cross-validation bandwidth for the local polynomial estimator of the psychometric function (PF) with guessing and lapsing rates specified in lims. The difference between this function and bandwidth_cross_validation is that here the true psychometric function is known.

Usage

1
bandwidth_optimal( ptrue, r, m, x, H, link = c( "logit" ), guessing = 0, lapsing = 0, K = 2, p = 1, ker = c( "dnorm" ), maxiter = 50, tol = 1e-6, method = c( "all" ) )

Arguments

ptrue

the true function. Vector with the value of PF at each design point

r

number of successes in points x

m

number of trials in points x

x

design points

H

minimum and maximum values of bandwidth to be considered

link

name of the link function to be used; default is "logit"

guessing

guessing rate; default is 0

lapsing

lapsing rate; default is 0

K

power parameter for Weibull and reverse Weibull link; default is 2

p

order of the polynomial; default is 1

ker

kernel function for weights; default "dnorm"

maxiter

maximum number of iterations in Fisher scoring; default is 50

tol

tolerance level at which to stop Fisher scoring; default is 1e-6

method

loss function to be used in cross-validation: choose from: 'ISEeta', 'ISE', 'deviance'; default is "all"

Value

h

cross-validation bandwidth for the chosen method; if no method was specified,then it a list of three elements with entries corresponding to the estimated bandwidths on p-scale (h$pscale), on eta-scale (h$etascale) and for mean likelihood (h$deviance)


modelfree documentation built on May 2, 2019, 6:07 p.m.