spatpcaCVWithSelectingK: Internal function: M-fold CV of SpatPCA with selecting K

Description Usage Arguments Value

View source: R/SpatPCA.R

Description

Internal function: M-fold CV of SpatPCA with selecting K

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
spatpcaCVWithSelectingK(
  x,
  Y,
  M,
  tau1,
  tau2,
  gamma,
  shuffle_split,
  maxit,
  thr,
  l2
)

Arguments

x

Location matrix

Y

Data matrix

M

The number of folds for cross validation; default is 5.

tau1

Vector of a nonnegative smoothness parameter sequence. If NULL, 10 tau1 values in a range are used.

tau2

Vector of a nonnegative sparseness parameter sequence. If NULL, none of tau2 is used.

gamma

Vector of a nonnegative hyper parameter sequence for tuning eigenvalues. If NULL, 10 values in a range are used.

shuffle_split

Vector of indeces for random splitting Y into training and test sets

maxit

Maximum number of iterations. Default value is 100.

thr

Threshold for convergence. Default value is 10^{-4}.

l2

Vector of a nonnegative tuning parameter sequence for ADMM use

Value

A list of objects including

cv_result

A list of resultant objects produced by spatpcaCV

selected_K

Selected K based on CV.


SpatPCA documentation built on Jan. 31, 2021, 5:05 p.m.