lab4ab-package: Linear regression

Description Author(s) Examples

Description

Compute linear regression when a set of observations and the dependent and indipendent variables are given.

'linreg$new()' helps to calculate all the most significative elements of a linear regression in just one step just giving the observations (contained in a dataset) and the formula.

The package also provides a printing method ($print()), a summary ($summary()) and two plots ($plot()).

The printing shows the coefficients found in the linear regression and their names; the summary acts just as the one of the lm() function; the two plots represent the the relationship between the fitted value and the residuals (the actual value and the square of the standardized value).

Author(s)

Alessia De Biase, Bruno Barakat

Maintainer: Bruno Barakat

Examples

1
2
3
4
5
6
7
8
9
data <- iris

formula <- Petal.Length ~ Sepal.Width + Sepal.Length

my_linear_reg <- linreg$new(formula, data)

my_linear_reg$print()
my_linear_reg$plot()
my_linear_reg$summary()

brbatv/lab4 documentation built on May 3, 2019, 2:56 p.m.