diff --git a/examples/gaussian_process/plot_gpr_prior_posterior.py b/examples/gaussian_process/plot_gpr_prior_posterior.py index e0f1a05ad3ec9..df4ab89719678 100644 --- a/examples/gaussian_process/plot_gpr_prior_posterior.py +++ b/examples/gaussian_process/plot_gpr_prior_posterior.py @@ -126,8 +126,8 @@ def plot_gpr_samples(gpr_model, n_samples, ax): ) # %% -# Rational Quadradtic kernel -# .......................... +# Rational Quadratic kernel +# ......................... from sklearn.gaussian_process.kernels import RationalQuadratic kernel = 1.0 * RationalQuadratic(length_scale=1.0, alpha=0.1, alpha_bounds=(1e-5, 1e15)) @@ -200,7 +200,7 @@ def plot_gpr_samples(gpr_model, n_samples, ax): kernel = ConstantKernel(0.1, (0.01, 10.0)) * ( DotProduct(sigma_0=1.0, sigma_0_bounds=(0.1, 10.0)) ** 2 ) -gpr = GaussianProcessRegressor(kernel=kernel, random_state=0) +gpr = GaussianProcessRegressor(kernel=kernel, random_state=0, normalize_y=True) fig, axs = plt.subplots(nrows=2, sharex=True, sharey=True, figsize=(10, 8))