Learn R Programming

matrixpls (version 0.7.0)

matrixpls.boot: Bootstrapping of matrixpls function

Description

matrixpls.boot is a convenience method that implements bootstrapping of matrixpls with boot method of the boot package.

Usage

matrixpls.boot(data, ..., R = 500, signChangeCorrection = NULL,
  parallel = c("no", "multicore", "snow"), ncpus = getOption("boot.ncpus",
  1L), stopOnError = FALSE, extraFun = NULL)

Arguments

data
Matrix or data frame containing the raw data.
...
All other arguments are passed through to matrixpls.
R
Number of bootstrap samples to draw.
signChangeCorrection
Sign change correction function.
parallel
The type of parallel operation to be used (if any). If missing, the default is taken from the option "boot.parallel" (and if that is not set, "no").
ncpus
integer: number of processes to be used in parallel operation: typically one would chose this to the number of available CPUs.
stopOnError
A logical indicating whether boostrapping should be continued when error occurs in a replication.
extraFun
A function that takes a matrixpls object and returns a numeric vector. The vector is appended to bootstrap replication. Can be used for boostrapping additional statistics calculated based on the estimation results.

Value

  • An object of class matrixplsboot and boot.

Analyzing the boostrap results

The output can be analyzed with any of the functions provided by the boot package. For example, the boot.ci function can be used for calculating confidence intervals and the empinf function can be used to calculate influence values that may be useful for identifying outliers.

The class matrixplsboot provides only a summary function, which calculates a set of statistics that are commonly of interest after boostrapping. This includes standard errors, t statistics (estimate / SE) and p-values based on Student's t distribution and standard normal distribution. Because the sampling distribution of the parameter estimates calculated by matrixpls are not always known, the p-values cannot be expected to be unbiased.

This concern applies particularly when using PLS weights. Because the PLS literature provides conflicting advice on which probability distribution to use as a reference, the summary method of matrixplsboot produces two-tailed p-values based on four different probalility distributions. The regression p values are based on comparing the t statistic against the references distribution used in regression analysis, namely Student's t distribution with n - k - 1 degrees of freedom. The Hair p values are based on Hair et al's (2014, p. 134) recommendation to ignore the number of independent variables k and set the degrees of freedom to n - 1. The Henseler p values are based on the recommendation by Henseler et al (2009, p. 305) that the degrees of freedom should be set as n + m - 2, where mis always 1 and n is the number of bootstrap samples. The z p values are based on comparing the t statistic against the standard normal distibution. This choice can be motivated by asymptotic normality of the PLS estimates in certain conditions.

See Also

boot

Sign change corrections: signChange.individual; signChange.construct

Examples

Run this code
library(plspm)

# Run the customer satisfaction example form plspm

# load dataset satisfaction
data(satisfaction)
# inner model matrix
IMAG = c(0,0,0,0,0,0)
EXPE = c(1,0,0,0,0,0)
QUAL = c(0,1,0,0,0,0)
VAL = c(0,1,1,0,0,0)
SAT = c(1,1,1,1,0,0)
LOY = c(1,0,0,0,1,0)
inner = rbind(IMAG, EXPE, QUAL, VAL, SAT, LOY)
colnames(inner) <- rownames(inner)

# Reflective model

reflective<- matrix(
  c(1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
    0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0,
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0,
    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1),
  27,6, dimnames = list(colnames(satisfaction)[1:27],colnames(inner)))

# empty formative model

formative <- matrix(0, 6, 27, dimnames = list(colnames(inner),
                                              colnames(satisfaction)[1:27]))

# Only 100 replications to make the example faster when running on single processor. 
# Increase the number of replications (e.g. to 500) to get the BCa intervals

matrixpls.boot.out <- matrixpls.boot(satisfaction[,1:27],
                           model = list(inner = inner,
                                        reflective = reflective,
                                        formative = formative),
                           R = 100)

print(matrixpls.boot.out)
summary(matrixpls.boot.out)

Run the code above in your browser using DataLab