Learn R Programming

QTOCen (version 0.1.1)

Bnk_func: Generate biquadratic kernel weights for a univariate variable

Description

This is the biquadratic kernel function, that weights observations by their distances to the target observation.

Usage

Bnk_func(x0k, Xk, bw.bnk)

Arguments

x0k

Numeric scalar. One univariate covariate value of interest from one observation.

Xk

Numerical vector. The vector of the same covariate from observations

bw.bnk

The bandwith scalar parameter.

Value

This function returns a list of kernel weights with the same length of input Xk.

References

wang2009locallyQTOCen

Examples

Run this code
# NOT RUN {
 
Bnk_func(x0k=0, Xk=c(-5:5), bw.bnk=10)

# }

Run the code above in your browser using DataLab