which is also required for prediction. If kernel == "precomputed" this is instead the precomputed training matrix, of shape (n_samples, n_samples). n_features_in_ : int Number of features seen during :term:`fit`. .. versionadded:: 0.24 feature_names_in_ : ndarray of shape (`n_features_in_`,) Names of features seen during :term:`fit`. Defined only when `X` has feature names that are all strings. .. versionadded:: 1.0 See Also -------- sklearn.gaussian_process.GaussianProcessRegressor : Gaussian Process regressor providing automatic kernel hyperparameters tuning and predictions uncertainty. sklearn.linear_model.Ridge : Linear ridge regression. sklearn.linear_model.RidgeCV : Ridge regression with built-in cross-validation. sklearn.svm.SVR : Support Vector Regression accepting a large variety of kernels. References ---------- * Kevin P. Murphy "Machine Learning: A Probabilistic Perspective", The MIT Press chapter 14.4.3, pp. 492-493 Examples -------- >>> from sklearn.kernel_ridge import KernelRidge >>> import numpy as np >>> n_samples, n_features = 10, 5 >>> rng = np.random.RandomState(0) >>> y = rng.randn(n_samples) >>> X = rng.randn(n_samples, n_features) >>> krr = KernelRidge(alpha=1.0) >>> krr.fit(X, y) KernelRidge(alpha=1.0) r