DEDICATED TO THE SAFE OBSERVATION OF THE TOTAL SOLAR ECLIPSE OF APRIL 8, 2024!
The eclipse is over.
We hope you enjoyed it!
 
 
Another TOTAL ECLIPSE
is coming to
North America!

It’s the Great North American Eclipse!
...and we want everyone to see it!
 
Your use of this site is contingent on your understanding and agreement that you will comply
with all the rules and protocols for eye safety when observing any solar phenomenon.
 
Latest News:

Nadar Logistic 🔥 Fast

: When linear logistic regression fails your validation set, and your data has few features—let the Nadaraya–Watson estimator draw you a smoother, more truthful curve.

What happens when the relationship is curved, clustered, or changes direction? Enter —a non-parametric, kernel-based method that lets the data "speak for itself." What is the Nadaraya–Watson Estimator? Originally designed for regression (continuous outcomes), the Nadaraya–Watson (NW) estimator predicts a value at a point ( x ) by calculating a weighted average of all observed outcomes. The weights are determined by a kernel (e.g., Gaussian, Epanechnikov), which gives high weight to training points near ( x ) and low weight to distant points. nadar logistic

[ \haty(x) = \frac\sum_i=1^n K\left(\fracx - x_ih\right) y_i\sum_i=1^n K\left(\fracx - x_ih\right) ] : When linear logistic regression fails your validation

preds = [] for x in x_test: weights = kernel_func((x - X_train) / h) weights = weights.flatten() p = np.sum(weights * y_train) / np.sum(weights) preds.append(p) return np.array(preds) Originally designed for regression (continuous outcomes)

Where ( K ) is the kernel function and ( h ) is the (smoothing parameter). Extending to Logistic Regression (Binary Outcomes) For binary outcomes (0/1), taking a simple weighted average would give a probability, but that probability would be unbounded and lack the formal link function of logistic regression. The Nadaraya–Watson approach adapts by estimating the conditional probability ( P(Y=1 | X=x) ) directly as a kernel-weighted average of the binary labels:

[ \hatp(x) = \frac\sum_i=1^n K\left(\fracx - x_ih\right) y_i\sum_i=1^n K\left(\fracx - x_ih\right) ]

In the world of binary classification (Yes/No, Churn/Stay, Sick/Healthy), Logistic Regression is the undisputed workhorse. However, standard logistic regression has a critical flaw: it assumes the log-odds of the outcome change linearly with the input features.