How do I interpret the regression output using Artificial Neural Network in R? I'm working on a covid-19 dataset, and I'm interested in using the Artificial Neural Network (ANN) to measure the effect of some independent variables namely: confirmed cases, new cases, and total deaths on the response variable new deaths. The attached is the output using R Kindly explain how to explain this output, it does not look like the normal linear regression I'm familiar with.
.
 A: Black represents the parameter weights.
Blue represents the bias terms (kind of like the intercept in linear regression).
To get the value of a neuron (black circle) towards the right, take the value in the circles to the left, multiply by the weight on the connecting line, and add up those values for all circles pointing towards your circle. We’d typically use a nonlinear activation function, too, such a ReLU, though you have not indicated what you used (if any).
I recommend writing out the full equation of this small neural network, and I hope no one ruins the fun for you before you try to work through it.
EDIT

$g = \text{activation}\big(0.01803 + 2.31748d + 1.00955e - 2.24362f\big)$
Use this to unpack the other six neurons. Then write $g$ in terms of the three predictor variables.
A: Let's simplify your figure and understand at a more generalized level. This neural network has three layers: Input, Hidden and Output. Each layer has multiple neurons whose activations are determined by:

*

*Activations of neurons from previous layer

*Weights and bias


Since this is a fully connected neural network or dense network, there are weights between each neuron between the layers. I have denoted weights by $\theta^{\text{layer 
number}}_{i, j}$, and bias with $b^{\text{layer number}}_{j}$ where $i$ is the neuron from previous layer and $j$ is the current neuron.
Now coming back to the figure you have provided, here are some example of weights and biases using my notation:

*

*$\theta^{2}_{1, 1}=0.35826$

*$\theta^{2}_{2, 1}=-6.11547$

*$\theta^{3}_{3, 1}=-2.24362$

*$b^{2}_{1}=0.85928$

*$b^{3}_{1}=0.01803$
and so on...

Now that we know what each symbol means let's write some equations to get activation of each neuron. Let's assume a $tanh$ activation function.
Second layer activations can be written as:
$$
h_1 = tanh(\theta^{2}_{1, 1}\:x_1 + \theta^{2}_{2, 1}\:x_2 + \theta^{2}_{3, 1}\:x_3 + b^{2}_{1}) = tanh \bigg( \sum_{i=1:3}\theta^{2}_{i, 1}\:x_i + b^{2}_{1} \bigg) \\
h_2 = tanh \bigg( \sum_{i=1:3}\theta^{2}_{i, 2}\:x_i + b^{2}_{2} \bigg) \\
h_3 = tanh \bigg( \sum_{i=1:3}\theta^{3}_{i, 2}\:x_i + b^{2}_{3} \bigg)
$$
And finally the output layer activations can be written as:
$$
y = tanh \bigg( \sum_{i=1:3}\theta^{3}_{i, 1}\:h_i + b^{3}_{1} \bigg)
$$
