cvek_test: Conduct Hypothesis Testing

Description Usage Arguments Details Value

View source: R/interface.R

Description

Conduct hypothesis testing based on CVEK estimation result.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
cvek_test(
  est_res,
  formula_test,
  kern_func_list,
  data,
  test = "boot",
  alt_kernel_type = "linear",
  B = 100,
  verbose = FALSE
)

Arguments

est_res

(list) Estimation results returned by estimation() procedure.

formula_test

(formula) A user-supplied formula indicating the alternative effect to test. All terms in the alternative mode must be specified as kernel terms.

kern_func_list

(list) A list of kernel functions in the kernel library

data

(data.frame, n*d) A data.frame, list or environment (or object coercible by as.data.frame to a data.frame), containing the variables in formula. Neither a matrix nor an array will be accepted.

test

(character) Type of hypothesis test to conduct. Must be either 'asymp' or 'boot'.

alt_kernel_type

(character) Type of alternative kernel effect to consider. Must be either 'linear' or 'ensemble'

B

(integer) A numeric value indicating times of resampling when test = "boot".

verbose

(logical) Whether to print additional messages.

Details

Conduct score tests comparing a fitted model and a more general alternative model.

There are two tests available here:

Asymptotic Test

This is based on the classical variance component test to construct a testing procedure for the hypothesis about Gaussian process function.

Bootstrap Test

When it comes to small sample size, we can use bootstrap test instead, which can give valid tests with moderate sample sizes and requires similar computational effort to a permutation test. In the case of bootstrap test, we can specify the form of the null derivative kernel (alt_kernel_type) to be linear or ensemble. The bootstrap test allows the null derivative kernel to be estimated adaptively from data using the same corresponding ensemble weights to better represent the alternative hypothesis space.

Value

pvalue

(numeric) p-value of the test.


CVEK documentation built on Jan. 8, 2021, 5:42 p.m.