To evaluate performance, we look at the difference between our prediction ( Ŷcap Y hat ) and the true label ( ). We use the formula:
We will build formulas for the first training row (X1=0, X2=0, Target=0) in columns F through K.
Your hidden layer is now live. Cells C3:F3 contain the activated values of H1 through H4.
The Mean Squared Error will drop from ~0.25 to <0.005. build neural network with ms excel full
| | F | G | | --- | --- | --- | | 1 | Activation Functions | | | 2 | Sigmoid | =1/(1+EXP(-A2)) | | 3 | ReLU | =MAX(0,A3) | | 4 | Tanh | =2/(1+EXP(-2*A4))-1 |
Select from the Manage dropdown menu and click Go . Check the box next to Solver Add-in and click OK .
Step-by-step: set up cells and formulas
The "learning" happens when you adjust weights to reduce the error. You have two main options in Excel:
Set up a dedicated in your spreadsheet (e.g., columns E through I): Hidden Layer Weights ( W(1)cap W raised to the open paren 1 close paren power ) and Biases ( B(1)cap B raised to the open paren 1 close paren power Node H1cap H sub 1 : Put weight W11cap W sub 11 in F2 , W21cap W sub 21 in F3 , and Bias B1cap B sub 1 in F4 . Node H2cap H sub 2 : Put weight W12cap W sub 12 in G2 , W22cap W sub 22 in G3 , and Bias B2cap B sub 2 in G4 . Node H3cap H sub 3 : Put weight W13cap W sub 13 in H2 , W23cap W sub 23 in H3 , and Bias B3cap B sub 3 in H4 .
The answer is surprisingly simple:
Multiply the hidden layer outputs by the output weights and add the output bias. =(N2*$L$2)+(O2*$M$2)+(P2*$N$2)+$O$2 Step 4: Calculate Final Prediction ( Ypredcap Y sub p r e d end-sub
), your network output cell should read close to (e.g., > 0.95 ). For inputs 1, 1 (
Want the full tutorial + free template? Like & RT, and I’ll DM the link. 👇 To evaluate performance, we look at the difference
Before you open Excel, you need to understand the core components that power every neural network.
Create a matrix for each layer. If you have 3 inputs and 4 hidden neurons, your weight matrix will be Biases (b):