Layers

There are three basic types of layers: input layers, hidden layers, and output layers. They respectively contain the input, hidden, and output nodes. Generally, you might have only a single input layer and a single output layer—each can contain one or more nodes—but you can have as many hidden layers as you want.

The number of input nodes is equal to number of input variables. The number of output nodes must be equal to the number of variables or categories predicted.

The following diagram shows a hypothetical arrangement for a feedforward NN:

Figure 8.4: Feedforward NN representation

Each circle represents a node, and the dashed arrows ...

Get Hands-On Data Science with R now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.