lm_graddescent: Create linear model using gradient descent

Description Usage Arguments Examples

View source: R/lm_graddescent.R

Description

This function creates a linear model using gradient descent.

Usage

1

Arguments

f

a formula the data will be fit too

d

the data to be fit (a data frame)

gamma

the step size (a positive number)

n

number of iterations (a positive integer)

contrasts

a list of variable names to be used as factor variables

Examples

1
2
3
data("iris")
irisform <- Sepal.Length ~.
lm_graddescent(irisform, iris, 0.0001, 100000)

kimgannon/bis557 documentation built on Nov. 25, 2020, 7:09 a.m.