masta.fit: Main function implementing the MASTA algorithm

Description Usage Arguments Value

View source: R/masta-fit.R

Description

This function builds an algorithm to identify the occurrence of event outcome from trajectories of several predictors.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
masta.fit(
  object,
  survival,
  follow_up_time,
  Tend = 1,
  cov_group = NULL,
  thresh = 0.7,
  PCAthresh = 0.9,
  seed = 100
)

Arguments

object

The object returned by the fpca.combine function

survival

the labeled data. The columns should be 1) id, 2) event indicator, 3) event time, followed by baseline predictors.

follow_up_time

the follow-up data

Tend

a scalar value. NA in SX is replaced by this. The default is 1.

cov_group

a vector of consecutive integers describing the grouping only for covariates. When NULL is specified (default), each covariate will be in different group.

thresh

a default is 0.7, which means if there are codes with >70% patients no codes, only use first code time.

PCAthresh

a threshold value for PCA. Default is 0.9.

seed

random seed used for the sampling. Default is 100.

Value

A list with components:

bgbbest_FromChengInit_BFGS

Details of the fitted model

Cstat_BrierSc_ChengInit_BFGS

Performance of the derived algorithm. C-statistics, etc.

group

A vector of consecutive integers describing the grouping coefficients


celehs/PETLER documentation built on Sept. 3, 2021, 8:21 a.m.