matrixMethod: The Method of Matrices

Description Usage Arguments Details Value Dependencies Author(s) References

Description

The method of matrices consists in build the matrix A and the matrix g.

Usage

1

Arguments

formula

a string character to be transformed as an object of class formula.

subset

optional vector which specifies the subset of observations to be used in the analysis.

weight

a list or numerical value for weigthed analysis.

family

a string character with the name of the error distribution and link function to be used in the analysis.

Details

If the experimenter has n independent variables and m observations, each of which can be expressed by the equation:

y[i] = β[0] + β[1]x[i] + β[2]x[2i] + ... + β[n]x[ni] + ε[i]

This model represents the equations system that describe the response values generated by fitting the regression. Using the matrix notation, according to \insertCitewalpole1993probabilitydistStatsServer, the equations system can be written as

y = Xβ + ε

In the X matrix, apart from the initial element, the ith row represents the x-values that give rise to the response yi. So A = X'X, g = X'y and the normal equations can be put in the matrix form AB = g.

Requires the function getVarbyFormula.

Value

A list with components:

xtx

a data matrix, the A matrix.

xty

a data matrix, the g matrix.

sum.y

a numerical value, the sum of elements for a given dependent variable y.

n.rows

a numerical value, the sample size.

Dependencies

getVarbyFormula

Author(s)

Paula R. Costa e Silva

References

\insertRef

walpole1993probabilitydistStatsServer


paularaissa/distStatsServer documentation built on June 19, 2019, 12:43 a.m.