simData1: Generate simulated data for 'SNPlm'

View source: R/simData1.R

simData1R Documentation

Generate simulated data for SNPlm

Description

Generate simulated data for users to apply the method SNPlm, including response variable y, scalar variable Z and sequence (genotypes) data X.

Usage

simData1(n, m, seed)

Arguments

n

an interger variable specifying the number of samples to be generated.

m

an interger variable specifying the sequence length of each sample.

seed

an integer variable specifying the random seed used for random sequence generation.

Value

An "simData1" object that contains the list of the following items.

  • y: a numeric vector representing the response variables.

  • z: a matrix representing the scalar covariates, with the number of rows equal to the number of samples.

  • location: a numeric vector defining the sampling sites of the sequence (genotypes) data.

  • X: a matrix representing the sequence data, with the number of rows equal to the number of samples.

  • beta: an "fd" object, representing the genetic effect function.

See Also

See Also as simX, SNPlm.

Examples

library(FunctanSNP)
n <- 300
m <- 30
simdata1 <- simData1(n, m, seed = 123)


FunctanSNP documentation built on Oct. 18, 2022, 5:08 p.m.