plsim.pTest | R Documentation |
Test whether some elements of α and β are zero, that is,
H_0: α_{i_1}=\cdots=α_{i_k}=0 \ \mbox{ and } β_{j_1}=\cdots=β_{j_l}=0
versus
H_1: \mbox{not \ all }\ α_{i_1},\cdots,α_{i_k} \ \mbox{ and } β_{j_1}, \cdots,β_{j_l} \ \mbox{ are equal to }\ 0.
plsim.pTest(fit, parameterSelected = NULL, TargetMethod = "plsimest")
fit |
the result of function plsim.est or plsim.vs.soft. |
parameterSelected |
select some coefficients for testing, default: NULL. |
TargetMethod |
default: "plsim.est". |
A list with class "htest" containing the following components
statistic |
the value of the test statistic. |
parameter |
the degree of freedom for the test |
p.value |
the p-value for the test |
method |
a character string indicating what type of test was performed |
data.name |
a character string giving the name of input |
H. Liang, X. Liu, R. Li, C. L. Tsai. Estimation and testing for partially linear single-index models. Annals of statistics, 2010, 38(6): 3811.
n = 50 sigma = 0.1 alpha = matrix(1,2,1) alpha = alpha/norm(alpha,"2") beta = matrix(4,1,1) x = matrix(1,n,1) z = matrix(runif(n*2),n,2) y = 4*((z%*%alpha-1/sqrt(2))^2) + x%*%beta + sigma*matrix(rnorm(n),n,1) # Obtain parameters in PLSiM using Profile Least Squares Estimator fit_plsimest = plsim.est(x, z, y) # Test whether the parameters of parametric part estimated by plsimest # are zero res_pTest_plsimest = plsim.pTest(fit_plsimest) # Test whether the second parameter of parametric part estimated by plsimest # is zero res_pTest_plsimest_ = plsim.pTest(fit_plsimest,parameterSelected = c(2)) # Obtain parameters in PLSiM using Penalized Profile Least Squares Estimator # with lambda set as 0.01 fit_plsim = plsim.vs.soft(x,z,y,lambda = 0.01) # Test whether the parameters of parametric part estimated by plsim are zero res_pTest_plsim = plsim.pTest(fit_plsim,TargetMethod = "plsim") # Test whether the second parameter of parametric part estimated by plsim is zero res_pTest_plsim_ = plsim.pTest(fit_plsim,parameterSelected = c(2),TargetMethod = "plsim")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.