chapter  12
18 Pages

Programming a Neural Network Using OOP in R

ByWilliam B. Claster

The object-oriented programming (OOP) paradigm provides elegant solutions to programming problems. This chapter presents such a solution for our neural network algorithm. The subject of OOP is vast, and one could spend a semester or more just studying the OOP design concepts. The chapter explains the most basic idea in just a few words. In many programming languages, we sometimes see code that uses the dot notation. A class is said to be like a blueprint. In the same way that a car manufacturer makes a blueprint for a particular model of car and then uses the blueprint to create many examples or “instances” of cars, in OOP, a class is a blueprint, and we can use it to create any number of instances of that class. In this implementation of a neural network, the chapter also discusses batch updating.