AGD: Accelerated Gradient Descent (AGD) Method Learning Function

Description Usage Arguments Details Value References See Also Examples

Description

A function to build prediction model using Accelerated Gradient Descent (AGD) method.

Usage

1
AGD(dataTrain, alpha = 0.1, maxIter = 10, momentum = 0.9, seed = NULL)

Arguments

dataTrain

a data.frame that representing training data (m \times n), where m is the number of instances and n is the number of variables where the last column is the output variable. dataTrain must have at least two columns and ten rows of data that contain only numbers (integer or float).

alpha

a float value representing learning rate. Default value is 0.1

maxIter

the maximal number of iterations.

momentum

a float value represent momentum give a constant speed to learning process.

seed

a integer value for static random. Default value is NULL, which means the function will not do static random.

Details

This function based on SGD and MGD with optimization to accelerate the learning with momentum constant in each iteration.

Value

a vector matrix of theta (coefficient) for linear model.

References

Y. Nesterov A method for unconstrained convex minimization problem with the rate of convergence O (1/k2), Soviet Mathematics Doklady 27 (2), pp. 543-547 (1983)

See Also

MGD

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
 
################################## 
## Learning and Build Model with AGD
## load R Package data  
data(gradDescentRData)
## get z-factor data
dataSet <- gradDescentRData$CompressilbilityFactor
## split dataset
splitedDataSet <- splitData(dataSet)
## build model with AGD
AGDmodel <- AGD(splitedDataSet$dataTrain) 
#show result
print(AGDmodel)

gradDescentR documentation built on March 9, 2017, 9:02 a.m.