Learn R Programming

Sieve (version 2.1)

Sieve-package: tools:::Rd_package_title("Sieve")

Description

tools:::Rd_package_description("Sieve")

Arguments

Author

tools:::Rd_package_author("Sieve")

Maintainer: tools:::Rd_package_maintainer("Sieve")

Details

The DESCRIPTION file: tools:::Rd_package_DESCRIPTION("Sieve") tools:::Rd_package_indices("Sieve") ~~ An overview of how to use the ~~ ~~ package, including the most ~~ ~~ important functions ~~

References

Tianyu Zhang and Noah Simon (2022) <arXiv:2206.02994>

Examples

Run this code

xdim <- 5
basisN <- 1000
type <- 'cosine'

#non-linear additive truth. Half of the features are truly associated with the outcome
TrainData <- GenSamples(s.size = 300, xdim = xdim, 
            frho = 'additive', frho.para = xdim/2)

#noise-free testing samples
TestData <- GenSamples(s.size = 1e3, xdim = xdim, noise.para = 0, 
            frho = 'additive', frho.para = xdim/2)

sieve.model <- sieve_preprocess(X = TrainData[,2:(xdim+1)], 
            basisN = basisN, type = type, interaction_order = 2)

sieve.model <- sieve_solver(sieve.model, TrainData$Y, l1 = TRUE)

sieve_model_prediction <- sieve_predict(testX = TestData[,2:(xdim+1)], 
                testY = TestData$Y, sieve.model)

Run the code above in your browser using DataLab