make.ncpen.data {ncpen}R Documentation

Create ncpen Data Structure Using a Formula

Description

This function creates ncpen y vector and x matrix from data using formula.

Usage

make.ncpen.data(formula, data)

Arguments

formula

(formula) regression formula. Intercept will not be created.

data

(numeric matrix or data.frame) contains both y and X.

Value

List of y vector and x matrix.

y.vec

y vector

x.mat

x matrix

Author(s)

Dongshin Kim, Sunghoon Kwon, Sangin Lee

Examples

data = data.frame(y = 1:5, x1 = 6:10, x2 = 11:15);
formula = log(y) ~ log(x1) + x2;
make.ncpen.data(formula, data);


[Package ncpen version 1.0.0 Index]