In our original analysis, we used decision trees to predict deaths in the Titanic. Now, a new method is chosen: neural networks.
Neural nets are a powerful deep learning technique and are used for many classification and prediction problems from computer vision to natural language processing. A basic neural network has an input layer, an output layer, and a number of hidden layers, each of them summed, weighted, and "squashed", usually with a sigmoid function. An algorithm known as back-propagation is used to modify the weights after each training example has been applied.
The Neural Networks were created in the Scikit-Learn library. The accuracy of each network was measured in a custom function I predicted. The first one is simple, with 5 neurons in two hidden layers. The sigmoid function was used for activation, while the Adam function was used for optimization. Learning rate was high, at 0.1, while regularization was low at 0.000001. The max number of iterations was expanded.
A more complicated neural network was created with nine neurons in two hidden layers.
In summary, even simple neural networks can achieve very accurate predictions and can be used to solve many of the challenging problems of today!