🧠 Model internals
0.00000.00000.00000.0000Live calculations
| RawThe patient's measurement in its original units (mg/dL, kg/m², years). | Scaled xThe raw value after standardising: (raw − training mean) ÷ training standard deviation. Puts all features on the same scale so training is stable. | WeightHow strongly this feature pushes the prediction toward diabetes (positive) or away from it (negative). This is what the model learns. | |
|---|---|---|---|
| Glucose | – | – | – |
| BMI | – | – | – |
| Age | – | – | – |
Press Step or Play to begin training. The model starts with all weights at 0 (it predicts 50% for everyone).
Data and decision boundary
Blue region = model predicts no diabetes, red region = predicts diabetes (deeper colour = more confident). Dot size = age. The purple line is where the model is 50/50, drawn with Age held at its training average (a 3-feature model really has a plane; this is a 2-D slice of it).
Train vs test performance
Accuracy after every epoch. The test set is only measured here; the model never learns from it. If train keeps rising while test falls, the model is overfitting. With only 6 test patients the test line moves in big jumps.
Cost per epoch
Average log-loss over all 20 training patients, measured once at the end of every epoch (epoch 0 = untrained model, ln 2 ≈ 0.693).