🕷️ Crawler Inspector

URL Lookup

Direct Parameter Lookup

Raw Queries and Responses

1. Shard Calculation

Query:
Response:
Calculated Shard: 148 (from laksa184)

2. Crawled Status Check

Query:
Response:

3. Robots.txt Check

Query:
Response:

4. Spam/Ban Check

Query:
Response:

5. Seen Status Check

ℹ️ Skipped - page is already crawled

đź“„
INDEXABLE
âś…
CRAWLED
16 hours ago
🤖
ROBOTS ALLOWED

Page Info Filters

FilterStatusConditionDetails
HTTP statusPASSdownload_http_code = 200HTTP 200
Age cutoffPASSdownload_stamp > now() - 6 MONTH0 months ago
History dropPASSisNull(history_drop_reason)No drop reason
Spam/banPASSfh_dont_index != 1 AND ml_spam_score = 0ml_spam_score=0
CanonicalPASSmeta_canonical IS NULL OR = '' OR = src_unparsedNot set

Page Details

PropertyValue
URLhttps://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html
Last Crawled2026-04-12 06:46:36 (16 hours ago)
First Indexed2018-11-16 14:27:52 (7 years ago)
HTTP Status Code200
Meta Titlendcg_score — scikit-learn 1.8.0 documentation
Meta Descriptionnull
Meta Canonicalnull
Boilerpipe Text
sklearn.metrics. ndcg_score ( y_true , y_score , * , k = None , sample_weight = None , ignore_ties = False ) [source] # Compute Normalized Discounted Cumulative Gain. Sum the true scores ranked in the order induced by the predicted scores, after applying a logarithmic discount. Then divide by the best possible score (Ideal DCG, obtained for a perfect ranking) to obtain a score between 0 and 1. This ranking metric returns a high value if true labels are ranked high by y_score . Parameters : y_true array-like of shape (n_samples, n_labels) True targets of multilabel classification, or true scores of entities to be ranked. Negative values in y_true may result in an output that is not between 0 and 1. y_score array-like of shape (n_samples, n_labels) Target scores, can either be probability estimates, confidence values, or non-thresholded measure of decisions (as returned by “decision_function” on some classifiers). k int, default=None Only consider the highest k scores in the ranking. If None , use all outputs. sample_weight array-like of shape (n_samples,), default=None Sample weights. If None , all samples are given the same weight. ignore_ties bool, default=False Assume that there are no ties in y_score (which is likely to be the case if y_score is continuous) for efficiency gains. Returns : normalized_discounted_cumulative_gain float in [0., 1.] The averaged NDCG scores for all samples. See also dcg_score Discounted Cumulative Gain (not normalized). References Wikipedia entry for Discounted Cumulative Gain Jarvelin, K., & Kekalainen, J. (2002). Cumulated gain-based evaluation of IR techniques. ACM Transactions on Information Systems (TOIS), 20(4), 422-446. Wang, Y., Wang, L., Li, Y., He, D., Chen, W., & Liu, T. Y. (2013, May). A theoretical analysis of NDCG ranking measures. In Proceedings of the 26th Annual Conference on Learning Theory (COLT 2013) McSherry, F., & Najork, M. (2008, March). Computing information retrieval performance measures efficiently in the presence of tied scores. In European conference on information retrieval (pp. 414-421). Springer, Berlin, Heidelberg. Examples >>> import numpy as np >>> from sklearn.metrics import ndcg_score >>> # we have ground-truth relevance of some answers to a query: >>> true_relevance = np . asarray ([[ 10 , 0 , 0 , 1 , 5 ]]) >>> # we predict some scores (relevance) for the answers >>> scores = np . asarray ([[ .1 , .2 , .3 , 4 , 70 ]]) >>> ndcg_score ( true_relevance , scores ) 0.69 >>> scores = np . asarray ([[ .05 , 1.1 , 1. , .5 , .0 ]]) >>> ndcg_score ( true_relevance , scores ) 0.49 >>> # we can set k to truncate the sum; only top k answers contribute. >>> ndcg_score ( true_relevance , scores , k = 4 ) 0.35 >>> # the normalization takes k into account so a perfect answer >>> # would still get 1.0 >>> ndcg_score ( true_relevance , true_relevance , k = 4 ) 1.0... >>> # now we have some ties in our prediction >>> scores = np . asarray ([[ 1 , 0 , 0 , 0 , 1 ]]) >>> # by default ties are averaged, so here we get the average (normalized) >>> # true relevance of our top predictions: (10 / 10 + 5 / 10) / 2 = .75 >>> ndcg_score ( true_relevance , scores , k = 1 ) 0.75 >>> # we can choose to ignore ties for faster results, but only >>> # if we know there aren't ties in our scores, otherwise we get >>> # wrong results: >>> ndcg_score ( true_relevance , ... scores , k = 1 , ignore_ties = True ) 0.5...
Markdown
[Skip to main content](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html#main-content) Back to top [![scikit-learn homepage](https://scikit-learn.org/stable/_static/scikit-learn-logo-without-subtitle.svg) ![scikit-learn homepage](https://scikit-learn.org/stable/_static/scikit-learn-logo-without-subtitle.svg)](https://scikit-learn.org/stable/index.html) - [Install](https://scikit-learn.org/stable/install.html) - [User Guide](https://scikit-learn.org/stable/user_guide.html) - [API](https://scikit-learn.org/stable/api/index.html) - [Examples](https://scikit-learn.org/stable/auto_examples/index.html) - [Community](https://blog.scikit-learn.org/) - More - [Getting Started](https://scikit-learn.org/stable/getting_started.html) - [Release History](https://scikit-learn.org/stable/whats_new.html) - [Glossary](https://scikit-learn.org/stable/glossary.html) - [Development](https://scikit-learn.org/dev/developers/index.html) - [FAQ](https://scikit-learn.org/stable/faq.html) - [Support](https://scikit-learn.org/stable/support.html) - [Related Projects](https://scikit-learn.org/stable/related_projects.html) - [Roadmap](https://scikit-learn.org/stable/roadmap.html) - [Governance](https://scikit-learn.org/stable/governance.html) - [About us](https://scikit-learn.org/stable/about.html) - [GitHub](https://github.com/scikit-learn/scikit-learn) 1\.8.0 (stable) [1\.9.dev0 (dev)](https://scikit-learn.org/dev/modules/generated/sklearn.metrics.ndcg_score.html)[1\.8.0 (stable)](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html)[1\.7.2](https://scikit-learn.org/1.7/modules/generated/sklearn.metrics.ndcg_score.html)[1\.6.1](https://scikit-learn.org/1.6/modules/generated/sklearn.metrics.ndcg_score.html)[1\.5.2](https://scikit-learn.org/1.5/modules/generated/sklearn.metrics.ndcg_score.html)[1\.4.2](https://scikit-learn.org/1.4/modules/generated/sklearn.metrics.ndcg_score.html)[1\.3.2](https://scikit-learn.org/1.3/modules/generated/sklearn.metrics.ndcg_score.html) - [Install](https://scikit-learn.org/stable/install.html) - [User Guide](https://scikit-learn.org/stable/user_guide.html) - [API](https://scikit-learn.org/stable/api/index.html) - [Examples](https://scikit-learn.org/stable/auto_examples/index.html) - [Community](https://blog.scikit-learn.org/) - [Getting Started](https://scikit-learn.org/stable/getting_started.html) - [Release History](https://scikit-learn.org/stable/whats_new.html) - [Glossary](https://scikit-learn.org/stable/glossary.html) - [Development](https://scikit-learn.org/dev/developers/index.html) - [FAQ](https://scikit-learn.org/stable/faq.html) - [Support](https://scikit-learn.org/stable/support.html) - [Related Projects](https://scikit-learn.org/stable/related_projects.html) - [Roadmap](https://scikit-learn.org/stable/roadmap.html) - [Governance](https://scikit-learn.org/stable/governance.html) - [About us](https://scikit-learn.org/stable/about.html) - [GitHub](https://github.com/scikit-learn/scikit-learn) 1\.8.0 (stable) [1\.9.dev0 (dev)](https://scikit-learn.org/dev/modules/generated/sklearn.metrics.ndcg_score.html)[1\.8.0 (stable)](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html)[1\.7.2](https://scikit-learn.org/1.7/modules/generated/sklearn.metrics.ndcg_score.html)[1\.6.1](https://scikit-learn.org/1.6/modules/generated/sklearn.metrics.ndcg_score.html)[1\.5.2](https://scikit-learn.org/1.5/modules/generated/sklearn.metrics.ndcg_score.html)[1\.4.2](https://scikit-learn.org/1.4/modules/generated/sklearn.metrics.ndcg_score.html)[1\.3.2](https://scikit-learn.org/1.3/modules/generated/sklearn.metrics.ndcg_score.html) Section Navigation - [sklearn](https://scikit-learn.org/stable/api/sklearn.html) - [config\_context](https://scikit-learn.org/stable/modules/generated/sklearn.config_context.html) - [get\_config](https://scikit-learn.org/stable/modules/generated/sklearn.get_config.html) - [set\_config](https://scikit-learn.org/stable/modules/generated/sklearn.set_config.html) - [show\_versions](https://scikit-learn.org/stable/modules/generated/sklearn.show_versions.html) - [sklearn.base](https://scikit-learn.org/stable/api/sklearn.base.html) - [BaseEstimator](https://scikit-learn.org/stable/modules/generated/sklearn.base.BaseEstimator.html) - [BiclusterMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.BiclusterMixin.html) - [ClassNamePrefixFeaturesOutMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.ClassNamePrefixFeaturesOutMixin.html) - [ClassifierMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.ClassifierMixin.html) - [ClusterMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.ClusterMixin.html) - [DensityMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.DensityMixin.html) - [MetaEstimatorMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.MetaEstimatorMixin.html) - [OneToOneFeatureMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.OneToOneFeatureMixin.html) - [OutlierMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.OutlierMixin.html) - [RegressorMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.RegressorMixin.html) - [TransformerMixin](https://scikit-learn.org/stable/modules/generated/sklearn.base.TransformerMixin.html) - [clone](https://scikit-learn.org/stable/modules/generated/sklearn.base.clone.html) - [is\_classifier](https://scikit-learn.org/stable/modules/generated/sklearn.base.is_classifier.html) - [is\_clusterer](https://scikit-learn.org/stable/modules/generated/sklearn.base.is_clusterer.html) - [is\_regressor](https://scikit-learn.org/stable/modules/generated/sklearn.base.is_regressor.html) - [is\_outlier\_detector](https://scikit-learn.org/stable/modules/generated/sklearn.base.is_outlier_detector.html) - [sklearn.calibration](https://scikit-learn.org/stable/api/sklearn.calibration.html) - [CalibratedClassifierCV](https://scikit-learn.org/stable/modules/generated/sklearn.calibration.CalibratedClassifierCV.html) - [calibration\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.calibration.calibration_curve.html) - [CalibrationDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.calibration.CalibrationDisplay.html) - [sklearn.cluster](https://scikit-learn.org/stable/api/sklearn.cluster.html) - [AffinityPropagation](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.AffinityPropagation.html) - [AgglomerativeClustering](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.AgglomerativeClustering.html) - [Birch](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.Birch.html) - [BisectingKMeans](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.BisectingKMeans.html) - [DBSCAN](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.DBSCAN.html) - [FeatureAgglomeration](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.FeatureAgglomeration.html) - [HDBSCAN](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.HDBSCAN.html) - [KMeans](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.KMeans.html) - [MeanShift](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.MeanShift.html) - [MiniBatchKMeans](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.MiniBatchKMeans.html) - [OPTICS](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.OPTICS.html) - [SpectralBiclustering](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.SpectralBiclustering.html) - [SpectralClustering](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.SpectralClustering.html) - [SpectralCoclustering](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.SpectralCoclustering.html) - [affinity\_propagation](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.affinity_propagation.html) - [cluster\_optics\_dbscan](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.cluster_optics_dbscan.html) - [cluster\_optics\_xi](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.cluster_optics_xi.html) - [compute\_optics\_graph](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.compute_optics_graph.html) - [dbscan](https://scikit-learn.org/stable/modules/generated/dbscan-function.html) - [estimate\_bandwidth](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.estimate_bandwidth.html) - [k\_means](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.k_means.html) - [kmeans\_plusplus](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.kmeans_plusplus.html) - [mean\_shift](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.mean_shift.html) - [spectral\_clustering](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.spectral_clustering.html) - [ward\_tree](https://scikit-learn.org/stable/modules/generated/sklearn.cluster.ward_tree.html) - [sklearn.compose](https://scikit-learn.org/stable/api/sklearn.compose.html) - [ColumnTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.compose.ColumnTransformer.html) - [TransformedTargetRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.compose.TransformedTargetRegressor.html) - [make\_column\_selector](https://scikit-learn.org/stable/modules/generated/sklearn.compose.make_column_selector.html) - [make\_column\_transformer](https://scikit-learn.org/stable/modules/generated/sklearn.compose.make_column_transformer.html) - [sklearn.covariance](https://scikit-learn.org/stable/api/sklearn.covariance.html) - [EllipticEnvelope](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.EllipticEnvelope.html) - [EmpiricalCovariance](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.EmpiricalCovariance.html) - [GraphicalLasso](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.GraphicalLasso.html) - [GraphicalLassoCV](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.GraphicalLassoCV.html) - [LedoitWolf](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.LedoitWolf.html) - [MinCovDet](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.MinCovDet.html) - [OAS](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.OAS.html) - [ShrunkCovariance](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.ShrunkCovariance.html) - [empirical\_covariance](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.empirical_covariance.html) - [graphical\_lasso](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.graphical_lasso.html) - [ledoit\_wolf](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.ledoit_wolf.html) - [ledoit\_wolf\_shrinkage](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.ledoit_wolf_shrinkage.html) - [oas](https://scikit-learn.org/stable/modules/generated/oas-function.html) - [shrunk\_covariance](https://scikit-learn.org/stable/modules/generated/sklearn.covariance.shrunk_covariance.html) - [sklearn.cross\_decomposition](https://scikit-learn.org/stable/api/sklearn.cross_decomposition.html) - [CCA](https://scikit-learn.org/stable/modules/generated/sklearn.cross_decomposition.CCA.html) - [PLSCanonical](https://scikit-learn.org/stable/modules/generated/sklearn.cross_decomposition.PLSCanonical.html) - [PLSRegression](https://scikit-learn.org/stable/modules/generated/sklearn.cross_decomposition.PLSRegression.html) - [PLSSVD](https://scikit-learn.org/stable/modules/generated/sklearn.cross_decomposition.PLSSVD.html) - [sklearn.datasets](https://scikit-learn.org/stable/api/sklearn.datasets.html) - [clear\_data\_home](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.clear_data_home.html) - [dump\_svmlight\_file](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.dump_svmlight_file.html) - [fetch\_20newsgroups](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_20newsgroups.html) - [fetch\_20newsgroups\_vectorized](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_20newsgroups_vectorized.html) - [fetch\_california\_housing](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_california_housing.html) - [fetch\_covtype](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_covtype.html) - [fetch\_file](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_file.html) - [fetch\_kddcup99](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_kddcup99.html) - [fetch\_lfw\_pairs](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_lfw_pairs.html) - [fetch\_lfw\_people](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_lfw_people.html) - [fetch\_olivetti\_faces](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_olivetti_faces.html) - [fetch\_openml](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_openml.html) - [fetch\_rcv1](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_rcv1.html) - [fetch\_species\_distributions](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.fetch_species_distributions.html) - [get\_data\_home](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.get_data_home.html) - [load\_breast\_cancer](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_breast_cancer.html) - [load\_diabetes](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_diabetes.html) - [load\_digits](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_digits.html) - [load\_files](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_files.html) - [load\_iris](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_iris.html) - [load\_linnerud](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_linnerud.html) - [load\_sample\_image](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_sample_image.html) - [load\_sample\_images](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_sample_images.html) - [load\_svmlight\_file](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_svmlight_file.html) - [load\_svmlight\_files](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_svmlight_files.html) - [load\_wine](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_wine.html) - [make\_biclusters](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_biclusters.html) - [make\_blobs](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_blobs.html) - [make\_checkerboard](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_checkerboard.html) - [make\_circles](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_circles.html) - [make\_classification](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_classification.html) - [make\_friedman1](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_friedman1.html) - [make\_friedman2](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_friedman2.html) - [make\_friedman3](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_friedman3.html) - [make\_gaussian\_quantiles](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_gaussian_quantiles.html) - [make\_hastie\_10\_2](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_hastie_10_2.html) - [make\_low\_rank\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_low_rank_matrix.html) - [make\_moons](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_moons.html) - [make\_multilabel\_classification](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_multilabel_classification.html) - [make\_regression](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_regression.html) - [make\_s\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_s_curve.html) - [make\_sparse\_coded\_signal](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_sparse_coded_signal.html) - [make\_sparse\_spd\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_sparse_spd_matrix.html) - [make\_sparse\_uncorrelated](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_sparse_uncorrelated.html) - [make\_spd\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_spd_matrix.html) - [make\_swiss\_roll](https://scikit-learn.org/stable/modules/generated/sklearn.datasets.make_swiss_roll.html) - [sklearn.decomposition](https://scikit-learn.org/stable/api/sklearn.decomposition.html) - [DictionaryLearning](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.DictionaryLearning.html) - [FactorAnalysis](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.FactorAnalysis.html) - [FastICA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.FastICA.html) - [IncrementalPCA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.IncrementalPCA.html) - [KernelPCA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.KernelPCA.html) - [LatentDirichletAllocation](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.LatentDirichletAllocation.html) - [MiniBatchDictionaryLearning](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.MiniBatchDictionaryLearning.html) - [MiniBatchNMF](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.MiniBatchNMF.html) - [MiniBatchSparsePCA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.MiniBatchSparsePCA.html) - [NMF](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.NMF.html) - [PCA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.PCA.html) - [SparseCoder](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.SparseCoder.html) - [SparsePCA](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.SparsePCA.html) - [TruncatedSVD](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.TruncatedSVD.html) - [dict\_learning](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.dict_learning.html) - [dict\_learning\_online](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.dict_learning_online.html) - [fastica](https://scikit-learn.org/stable/modules/generated/fastica-function.html) - [non\_negative\_factorization](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.non_negative_factorization.html) - [sparse\_encode](https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.sparse_encode.html) - [sklearn.discriminant\_analysis](https://scikit-learn.org/stable/api/sklearn.discriminant_analysis.html) - [LinearDiscriminantAnalysis](https://scikit-learn.org/stable/modules/generated/sklearn.discriminant_analysis.LinearDiscriminantAnalysis.html) - [QuadraticDiscriminantAnalysis](https://scikit-learn.org/stable/modules/generated/sklearn.discriminant_analysis.QuadraticDiscriminantAnalysis.html) - [sklearn.dummy](https://scikit-learn.org/stable/api/sklearn.dummy.html) - [DummyClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.dummy.DummyClassifier.html) - [DummyRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.dummy.DummyRegressor.html) - [sklearn.ensemble](https://scikit-learn.org/stable/api/sklearn.ensemble.html) - [AdaBoostClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.AdaBoostClassifier.html) - [AdaBoostRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.AdaBoostRegressor.html) - [BaggingClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.BaggingClassifier.html) - [BaggingRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.BaggingRegressor.html) - [ExtraTreesClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.ExtraTreesClassifier.html) - [ExtraTreesRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.ExtraTreesRegressor.html) - [GradientBoostingClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.GradientBoostingClassifier.html) - [GradientBoostingRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.GradientBoostingRegressor.html) - [HistGradientBoostingClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.HistGradientBoostingClassifier.html) - [HistGradientBoostingRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.HistGradientBoostingRegressor.html) - [IsolationForest](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.IsolationForest.html) - [RandomForestClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.RandomForestClassifier.html) - [RandomForestRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.RandomForestRegressor.html) - [RandomTreesEmbedding](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.RandomTreesEmbedding.html) - [StackingClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.StackingClassifier.html) - [StackingRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.StackingRegressor.html) - [VotingClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.VotingClassifier.html) - [VotingRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.VotingRegressor.html) - [sklearn.exceptions](https://scikit-learn.org/stable/api/sklearn.exceptions.html) - [ConvergenceWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.ConvergenceWarning.html) - [DataConversionWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.DataConversionWarning.html) - [DataDimensionalityWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.DataDimensionalityWarning.html) - [EfficiencyWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.EfficiencyWarning.html) - [FitFailedWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.FitFailedWarning.html) - [InconsistentVersionWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.InconsistentVersionWarning.html) - [NotFittedError](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.NotFittedError.html) - [UndefinedMetricWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.UndefinedMetricWarning.html) - [EstimatorCheckFailedWarning](https://scikit-learn.org/stable/modules/generated/sklearn.exceptions.EstimatorCheckFailedWarning.html) - [sklearn.experimental](https://scikit-learn.org/stable/api/sklearn.experimental.html) - [enable\_halving\_search\_cv](https://scikit-learn.org/stable/modules/generated/sklearn.experimental.enable_halving_search_cv.html) - [enable\_iterative\_imputer](https://scikit-learn.org/stable/modules/generated/sklearn.experimental.enable_iterative_imputer.html) - [sklearn.feature\_extraction](https://scikit-learn.org/stable/api/sklearn.feature_extraction.html) - [DictVectorizer](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.DictVectorizer.html) - [FeatureHasher](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.FeatureHasher.html) - [PatchExtractor](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.image.PatchExtractor.html) - [extract\_patches\_2d](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.image.extract_patches_2d.html) - [grid\_to\_graph](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.image.grid_to_graph.html) - [img\_to\_graph](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.image.img_to_graph.html) - [reconstruct\_from\_patches\_2d](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.image.reconstruct_from_patches_2d.html) - [CountVectorizer](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.text.CountVectorizer.html) - [HashingVectorizer](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.text.HashingVectorizer.html) - [TfidfTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.text.TfidfTransformer.html) - [TfidfVectorizer](https://scikit-learn.org/stable/modules/generated/sklearn.feature_extraction.text.TfidfVectorizer.html) - [sklearn.feature\_selection](https://scikit-learn.org/stable/api/sklearn.feature_selection.html) - [GenericUnivariateSelect](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.GenericUnivariateSelect.html) - [RFE](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.RFE.html) - [RFECV](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.RFECV.html) - [SelectFdr](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectFdr.html) - [SelectFpr](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectFpr.html) - [SelectFromModel](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectFromModel.html) - [SelectFwe](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectFwe.html) - [SelectKBest](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectKBest.html) - [SelectPercentile](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectPercentile.html) - [SelectorMixin](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SelectorMixin.html) - [SequentialFeatureSelector](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.SequentialFeatureSelector.html) - [VarianceThreshold](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.VarianceThreshold.html) - [chi2](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.chi2.html) - [f\_classif](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.f_classif.html) - [f\_regression](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.f_regression.html) - [mutual\_info\_classif](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.mutual_info_classif.html) - [mutual\_info\_regression](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.mutual_info_regression.html) - [r\_regression](https://scikit-learn.org/stable/modules/generated/sklearn.feature_selection.r_regression.html) - [sklearn.frozen](https://scikit-learn.org/stable/api/sklearn.frozen.html) - [FrozenEstimator](https://scikit-learn.org/stable/modules/generated/sklearn.frozen.FrozenEstimator.html) - [sklearn.gaussian\_process](https://scikit-learn.org/stable/api/sklearn.gaussian_process.html) - [GaussianProcessClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.GaussianProcessClassifier.html) - [GaussianProcessRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.GaussianProcessRegressor.html) - [CompoundKernel](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.CompoundKernel.html) - [ConstantKernel](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.ConstantKernel.html) - [DotProduct](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.DotProduct.html) - [ExpSineSquared](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.ExpSineSquared.html) - [Exponentiation](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.Exponentiation.html) - [Hyperparameter](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.Hyperparameter.html) - [Kernel](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.Kernel.html) - [Matern](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.Matern.html) - [PairwiseKernel](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.PairwiseKernel.html) - [Product](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.Product.html) - [RBF](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.RBF.html) - [RationalQuadratic](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.RationalQuadratic.html) - [Sum](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.Sum.html) - [WhiteKernel](https://scikit-learn.org/stable/modules/generated/sklearn.gaussian_process.kernels.WhiteKernel.html) - [sklearn.impute](https://scikit-learn.org/stable/api/sklearn.impute.html) - [IterativeImputer](https://scikit-learn.org/stable/modules/generated/sklearn.impute.IterativeImputer.html) - [KNNImputer](https://scikit-learn.org/stable/modules/generated/sklearn.impute.KNNImputer.html) - [MissingIndicator](https://scikit-learn.org/stable/modules/generated/sklearn.impute.MissingIndicator.html) - [SimpleImputer](https://scikit-learn.org/stable/modules/generated/sklearn.impute.SimpleImputer.html) - [sklearn.inspection](https://scikit-learn.org/stable/api/sklearn.inspection.html) - [partial\_dependence](https://scikit-learn.org/stable/modules/generated/sklearn.inspection.partial_dependence.html) - [permutation\_importance](https://scikit-learn.org/stable/modules/generated/sklearn.inspection.permutation_importance.html) - [DecisionBoundaryDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.inspection.DecisionBoundaryDisplay.html) - [PartialDependenceDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.inspection.PartialDependenceDisplay.html) - [sklearn.isotonic](https://scikit-learn.org/stable/api/sklearn.isotonic.html) - [IsotonicRegression](https://scikit-learn.org/stable/modules/generated/sklearn.isotonic.IsotonicRegression.html) - [check\_increasing](https://scikit-learn.org/stable/modules/generated/sklearn.isotonic.check_increasing.html) - [isotonic\_regression](https://scikit-learn.org/stable/modules/generated/sklearn.isotonic.isotonic_regression.html) - [sklearn.kernel\_approximation](https://scikit-learn.org/stable/api/sklearn.kernel_approximation.html) - [AdditiveChi2Sampler](https://scikit-learn.org/stable/modules/generated/sklearn.kernel_approximation.AdditiveChi2Sampler.html) - [Nystroem](https://scikit-learn.org/stable/modules/generated/sklearn.kernel_approximation.Nystroem.html) - [PolynomialCountSketch](https://scikit-learn.org/stable/modules/generated/sklearn.kernel_approximation.PolynomialCountSketch.html) - [RBFSampler](https://scikit-learn.org/stable/modules/generated/sklearn.kernel_approximation.RBFSampler.html) - [SkewedChi2Sampler](https://scikit-learn.org/stable/modules/generated/sklearn.kernel_approximation.SkewedChi2Sampler.html) - [sklearn.kernel\_ridge](https://scikit-learn.org/stable/api/sklearn.kernel_ridge.html) - [KernelRidge](https://scikit-learn.org/stable/modules/generated/sklearn.kernel_ridge.KernelRidge.html) - [sklearn.linear\_model](https://scikit-learn.org/stable/api/sklearn.linear_model.html) - [LogisticRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html) - [LogisticRegressionCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegressionCV.html) - [PassiveAggressiveClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.PassiveAggressiveClassifier.html) - [Perceptron](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.Perceptron.html) - [RidgeClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.RidgeClassifier.html) - [RidgeClassifierCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.RidgeClassifierCV.html) - [SGDClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.SGDClassifier.html) - [SGDOneClassSVM](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.SGDOneClassSVM.html) - [LinearRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LinearRegression.html) - [Ridge](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.Ridge.html) - [RidgeCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.RidgeCV.html) - [SGDRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.SGDRegressor.html) - [ElasticNet](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.ElasticNet.html) - [ElasticNetCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.ElasticNetCV.html) - [Lars](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.Lars.html) - [LarsCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LarsCV.html) - [Lasso](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.Lasso.html) - [LassoCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LassoCV.html) - [LassoLars](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LassoLars.html) - [LassoLarsCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LassoLarsCV.html) - [LassoLarsIC](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LassoLarsIC.html) - [OrthogonalMatchingPursuit](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.OrthogonalMatchingPursuit.html) - [OrthogonalMatchingPursuitCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.OrthogonalMatchingPursuitCV.html) - [ARDRegression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.ARDRegression.html) - [BayesianRidge](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.BayesianRidge.html) - [MultiTaskElasticNet](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.MultiTaskElasticNet.html) - [MultiTaskElasticNetCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.MultiTaskElasticNetCV.html) - [MultiTaskLasso](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.MultiTaskLasso.html) - [MultiTaskLassoCV](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.MultiTaskLassoCV.html) - [HuberRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.HuberRegressor.html) - [QuantileRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.QuantileRegressor.html) - [RANSACRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.RANSACRegressor.html) - [TheilSenRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.TheilSenRegressor.html) - [GammaRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.GammaRegressor.html) - [PoissonRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.PoissonRegressor.html) - [TweedieRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.TweedieRegressor.html) - [PassiveAggressiveRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.PassiveAggressiveRegressor.html) - [enet\_path](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.enet_path.html) - [lars\_path](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.lars_path.html) - [lars\_path\_gram](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.lars_path_gram.html) - [lasso\_path](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.lasso_path.html) - [orthogonal\_mp](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.orthogonal_mp.html) - [orthogonal\_mp\_gram](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.orthogonal_mp_gram.html) - [ridge\_regression](https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.ridge_regression.html) - [sklearn.manifold](https://scikit-learn.org/stable/api/sklearn.manifold.html) - [ClassicalMDS](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.ClassicalMDS.html) - [Isomap](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.Isomap.html) - [LocallyLinearEmbedding](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.LocallyLinearEmbedding.html) - [MDS](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.MDS.html) - [SpectralEmbedding](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.SpectralEmbedding.html) - [TSNE](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.TSNE.html) - [locally\_linear\_embedding](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.locally_linear_embedding.html) - [smacof](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.smacof.html) - [spectral\_embedding](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.spectral_embedding.html) - [trustworthiness](https://scikit-learn.org/stable/modules/generated/sklearn.manifold.trustworthiness.html) - [sklearn.metrics](https://scikit-learn.org/stable/api/sklearn.metrics.html) - [check\_scoring](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.check_scoring.html) - [get\_scorer](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.get_scorer.html) - [get\_scorer\_names](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.get_scorer_names.html) - [make\_scorer](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.make_scorer.html) - [accuracy\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.accuracy_score.html) - [auc](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.auc.html) - [average\_precision\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.average_precision_score.html) - [balanced\_accuracy\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.balanced_accuracy_score.html) - [brier\_score\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.brier_score_loss.html) - [class\_likelihood\_ratios](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.class_likelihood_ratios.html) - [classification\_report](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.classification_report.html) - [cohen\_kappa\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.cohen_kappa_score.html) - [confusion\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.confusion_matrix.html) - [confusion\_matrix\_at\_thresholds](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.confusion_matrix_at_thresholds.html) - [d2\_brier\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.d2_brier_score.html) - [d2\_log\_loss\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.d2_log_loss_score.html) - [dcg\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.dcg_score.html) - [det\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.det_curve.html) - [f1\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.f1_score.html) - [fbeta\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.fbeta_score.html) - [hamming\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.hamming_loss.html) - [hinge\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.hinge_loss.html) - [jaccard\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.jaccard_score.html) - [log\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.log_loss.html) - [matthews\_corrcoef](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.matthews_corrcoef.html) - [multilabel\_confusion\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.multilabel_confusion_matrix.html) - [ndcg\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html) - [precision\_recall\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.precision_recall_curve.html) - [precision\_recall\_fscore\_support](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.precision_recall_fscore_support.html) - [precision\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.precision_score.html) - [recall\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.recall_score.html) - [roc\_auc\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.roc_auc_score.html) - [roc\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.roc_curve.html) - [top\_k\_accuracy\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.top_k_accuracy_score.html) - [zero\_one\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.zero_one_loss.html) - [d2\_absolute\_error\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.d2_absolute_error_score.html) - [d2\_pinball\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.d2_pinball_score.html) - [d2\_tweedie\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.d2_tweedie_score.html) - [explained\_variance\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.explained_variance_score.html) - [max\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.max_error.html) - [mean\_absolute\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_absolute_error.html) - [mean\_absolute\_percentage\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_absolute_percentage_error.html) - [mean\_gamma\_deviance](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_gamma_deviance.html) - [mean\_pinball\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_pinball_loss.html) - [mean\_poisson\_deviance](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_poisson_deviance.html) - [mean\_squared\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_squared_error.html) - [mean\_squared\_log\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_squared_log_error.html) - [mean\_tweedie\_deviance](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mean_tweedie_deviance.html) - [median\_absolute\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.median_absolute_error.html) - [r2\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.r2_score.html) - [root\_mean\_squared\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.root_mean_squared_error.html) - [root\_mean\_squared\_log\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.root_mean_squared_log_error.html) - [coverage\_error](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.coverage_error.html) - [label\_ranking\_average\_precision\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.label_ranking_average_precision_score.html) - [label\_ranking\_loss](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.label_ranking_loss.html) - [adjusted\_mutual\_info\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.adjusted_mutual_info_score.html) - [adjusted\_rand\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.adjusted_rand_score.html) - [calinski\_harabasz\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.calinski_harabasz_score.html) - [contingency\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.cluster.contingency_matrix.html) - [pair\_confusion\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.cluster.pair_confusion_matrix.html) - [completeness\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.completeness_score.html) - [davies\_bouldin\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.davies_bouldin_score.html) - [fowlkes\_mallows\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.fowlkes_mallows_score.html) - [homogeneity\_completeness\_v\_measure](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.homogeneity_completeness_v_measure.html) - [homogeneity\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.homogeneity_score.html) - [mutual\_info\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.mutual_info_score.html) - [normalized\_mutual\_info\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.normalized_mutual_info_score.html) - [rand\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.rand_score.html) - [silhouette\_samples](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.silhouette_samples.html) - [silhouette\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.silhouette_score.html) - [v\_measure\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.v_measure_score.html) - [consensus\_score](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.consensus_score.html) - [DistanceMetric](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.DistanceMetric.html) - [additive\_chi2\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.additive_chi2_kernel.html) - [chi2\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.chi2_kernel.html) - [cosine\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.cosine_distances.html) - [cosine\_similarity](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.cosine_similarity.html) - [distance\_metrics](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.distance_metrics.html) - [euclidean\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.euclidean_distances.html) - [haversine\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.haversine_distances.html) - [kernel\_metrics](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.kernel_metrics.html) - [laplacian\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.laplacian_kernel.html) - [linear\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.linear_kernel.html) - [manhattan\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.manhattan_distances.html) - [nan\_euclidean\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.nan_euclidean_distances.html) - [paired\_cosine\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.paired_cosine_distances.html) - [paired\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.paired_distances.html) - [paired\_euclidean\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.paired_euclidean_distances.html) - [paired\_manhattan\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.paired_manhattan_distances.html) - [pairwise\_kernels](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.pairwise_kernels.html) - [polynomial\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.polynomial_kernel.html) - [rbf\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.rbf_kernel.html) - [sigmoid\_kernel](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.sigmoid_kernel.html) - [pairwise\_distances](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise_distances.html) - [pairwise\_distances\_argmin](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise_distances_argmin.html) - [pairwise\_distances\_argmin\_min](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise_distances_argmin_min.html) - [pairwise\_distances\_chunked](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise_distances_chunked.html) - [ConfusionMatrixDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ConfusionMatrixDisplay.html) - [DetCurveDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.DetCurveDisplay.html) - [PrecisionRecallDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.PrecisionRecallDisplay.html) - [PredictionErrorDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.PredictionErrorDisplay.html) - [RocCurveDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.RocCurveDisplay.html) - [sklearn.mixture](https://scikit-learn.org/stable/api/sklearn.mixture.html) - [BayesianGaussianMixture](https://scikit-learn.org/stable/modules/generated/sklearn.mixture.BayesianGaussianMixture.html) - [GaussianMixture](https://scikit-learn.org/stable/modules/generated/sklearn.mixture.GaussianMixture.html) - [sklearn.model\_selection](https://scikit-learn.org/stable/api/sklearn.model_selection.html) - [GroupKFold](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.GroupKFold.html) - [GroupShuffleSplit](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.GroupShuffleSplit.html) - [KFold](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.KFold.html) - [LeaveOneGroupOut](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.LeaveOneGroupOut.html) - [LeaveOneOut](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.LeaveOneOut.html) - [LeavePGroupsOut](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.LeavePGroupsOut.html) - [LeavePOut](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.LeavePOut.html) - [PredefinedSplit](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.PredefinedSplit.html) - [RepeatedKFold](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.RepeatedKFold.html) - [RepeatedStratifiedKFold](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.RepeatedStratifiedKFold.html) - [ShuffleSplit](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.ShuffleSplit.html) - [StratifiedGroupKFold](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.StratifiedGroupKFold.html) - [StratifiedKFold](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.StratifiedKFold.html) - [StratifiedShuffleSplit](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.StratifiedShuffleSplit.html) - [TimeSeriesSplit](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.TimeSeriesSplit.html) - [check\_cv](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.check_cv.html) - [train\_test\_split](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.train_test_split.html) - [GridSearchCV](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.GridSearchCV.html) - [HalvingGridSearchCV](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.HalvingGridSearchCV.html) - [HalvingRandomSearchCV](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.HalvingRandomSearchCV.html) - [ParameterGrid](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.ParameterGrid.html) - [ParameterSampler](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.ParameterSampler.html) - [RandomizedSearchCV](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.RandomizedSearchCV.html) - [FixedThresholdClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.FixedThresholdClassifier.html) - [TunedThresholdClassifierCV](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.TunedThresholdClassifierCV.html) - [cross\_val\_predict](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.cross_val_predict.html) - [cross\_val\_score](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.cross_val_score.html) - [cross\_validate](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.cross_validate.html) - [learning\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.learning_curve.html) - [permutation\_test\_score](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.permutation_test_score.html) - [validation\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.validation_curve.html) - [LearningCurveDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.LearningCurveDisplay.html) - [ValidationCurveDisplay](https://scikit-learn.org/stable/modules/generated/sklearn.model_selection.ValidationCurveDisplay.html) - [sklearn.multiclass](https://scikit-learn.org/stable/api/sklearn.multiclass.html) - [OneVsOneClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.multiclass.OneVsOneClassifier.html) - [OneVsRestClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.multiclass.OneVsRestClassifier.html) - [OutputCodeClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.multiclass.OutputCodeClassifier.html) - [sklearn.multioutput](https://scikit-learn.org/stable/api/sklearn.multioutput.html) - [ClassifierChain](https://scikit-learn.org/stable/modules/generated/sklearn.multioutput.ClassifierChain.html) - [MultiOutputClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.multioutput.MultiOutputClassifier.html) - [MultiOutputRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.multioutput.MultiOutputRegressor.html) - [RegressorChain](https://scikit-learn.org/stable/modules/generated/sklearn.multioutput.RegressorChain.html) - [sklearn.naive\_bayes](https://scikit-learn.org/stable/api/sklearn.naive_bayes.html) - [BernoulliNB](https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.BernoulliNB.html) - [CategoricalNB](https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.CategoricalNB.html) - [ComplementNB](https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.ComplementNB.html) - [GaussianNB](https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.GaussianNB.html) - [MultinomialNB](https://scikit-learn.org/stable/modules/generated/sklearn.naive_bayes.MultinomialNB.html) - [sklearn.neighbors](https://scikit-learn.org/stable/api/sklearn.neighbors.html) - [BallTree](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.BallTree.html) - [KDTree](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KDTree.html) - [KNeighborsClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KNeighborsClassifier.html) - [KNeighborsRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KNeighborsRegressor.html) - [KNeighborsTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KNeighborsTransformer.html) - [KernelDensity](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.KernelDensity.html) - [LocalOutlierFactor](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.LocalOutlierFactor.html) - [NearestCentroid](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.NearestCentroid.html) - [NearestNeighbors](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.NearestNeighbors.html) - [NeighborhoodComponentsAnalysis](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.NeighborhoodComponentsAnalysis.html) - [RadiusNeighborsClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.RadiusNeighborsClassifier.html) - [RadiusNeighborsRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.RadiusNeighborsRegressor.html) - [RadiusNeighborsTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.RadiusNeighborsTransformer.html) - [kneighbors\_graph](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.kneighbors_graph.html) - [radius\_neighbors\_graph](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.radius_neighbors_graph.html) - [sort\_graph\_by\_row\_values](https://scikit-learn.org/stable/modules/generated/sklearn.neighbors.sort_graph_by_row_values.html) - [sklearn.neural\_network](https://scikit-learn.org/stable/api/sklearn.neural_network.html) - [BernoulliRBM](https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.BernoulliRBM.html) - [MLPClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPClassifier.html) - [MLPRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPRegressor.html) - [sklearn.pipeline](https://scikit-learn.org/stable/api/sklearn.pipeline.html) - [FeatureUnion](https://scikit-learn.org/stable/modules/generated/sklearn.pipeline.FeatureUnion.html) - [Pipeline](https://scikit-learn.org/stable/modules/generated/sklearn.pipeline.Pipeline.html) - [make\_pipeline](https://scikit-learn.org/stable/modules/generated/sklearn.pipeline.make_pipeline.html) - [make\_union](https://scikit-learn.org/stable/modules/generated/sklearn.pipeline.make_union.html) - [sklearn.preprocessing](https://scikit-learn.org/stable/api/sklearn.preprocessing.html) - [Binarizer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.Binarizer.html) - [FunctionTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.FunctionTransformer.html) - [KBinsDiscretizer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.KBinsDiscretizer.html) - [KernelCenterer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.KernelCenterer.html) - [LabelBinarizer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.LabelBinarizer.html) - [LabelEncoder](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.LabelEncoder.html) - [MaxAbsScaler](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.MaxAbsScaler.html) - [MinMaxScaler](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.MinMaxScaler.html) - [MultiLabelBinarizer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.MultiLabelBinarizer.html) - [Normalizer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.Normalizer.html) - [OneHotEncoder](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.OneHotEncoder.html) - [OrdinalEncoder](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.OrdinalEncoder.html) - [PolynomialFeatures](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.PolynomialFeatures.html) - [PowerTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.PowerTransformer.html) - [QuantileTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.QuantileTransformer.html) - [RobustScaler](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.RobustScaler.html) - [SplineTransformer](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.SplineTransformer.html) - [StandardScaler](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.StandardScaler.html) - [TargetEncoder](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.TargetEncoder.html) - [add\_dummy\_feature](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.add_dummy_feature.html) - [binarize](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.binarize.html) - [label\_binarize](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.label_binarize.html) - [maxabs\_scale](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.maxabs_scale.html) - [minmax\_scale](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.minmax_scale.html) - [normalize](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.normalize.html) - [power\_transform](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.power_transform.html) - [quantile\_transform](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.quantile_transform.html) - [robust\_scale](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.robust_scale.html) - [scale](https://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.scale.html) - [sklearn.random\_projection](https://scikit-learn.org/stable/api/sklearn.random_projection.html) - [GaussianRandomProjection](https://scikit-learn.org/stable/modules/generated/sklearn.random_projection.GaussianRandomProjection.html) - [SparseRandomProjection](https://scikit-learn.org/stable/modules/generated/sklearn.random_projection.SparseRandomProjection.html) - [johnson\_lindenstrauss\_min\_dim](https://scikit-learn.org/stable/modules/generated/sklearn.random_projection.johnson_lindenstrauss_min_dim.html) - [sklearn.semi\_supervised](https://scikit-learn.org/stable/api/sklearn.semi_supervised.html) - [LabelPropagation](https://scikit-learn.org/stable/modules/generated/sklearn.semi_supervised.LabelPropagation.html) - [LabelSpreading](https://scikit-learn.org/stable/modules/generated/sklearn.semi_supervised.LabelSpreading.html) - [SelfTrainingClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.semi_supervised.SelfTrainingClassifier.html) - [sklearn.svm](https://scikit-learn.org/stable/api/sklearn.svm.html) - [LinearSVC](https://scikit-learn.org/stable/modules/generated/sklearn.svm.LinearSVC.html) - [LinearSVR](https://scikit-learn.org/stable/modules/generated/sklearn.svm.LinearSVR.html) - [NuSVC](https://scikit-learn.org/stable/modules/generated/sklearn.svm.NuSVC.html) - [NuSVR](https://scikit-learn.org/stable/modules/generated/sklearn.svm.NuSVR.html) - [OneClassSVM](https://scikit-learn.org/stable/modules/generated/sklearn.svm.OneClassSVM.html) - [SVC](https://scikit-learn.org/stable/modules/generated/sklearn.svm.SVC.html) - [SVR](https://scikit-learn.org/stable/modules/generated/sklearn.svm.SVR.html) - [l1\_min\_c](https://scikit-learn.org/stable/modules/generated/sklearn.svm.l1_min_c.html) - [sklearn.tree](https://scikit-learn.org/stable/api/sklearn.tree.html) - [DecisionTreeClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.tree.DecisionTreeClassifier.html) - [DecisionTreeRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.tree.DecisionTreeRegressor.html) - [ExtraTreeClassifier](https://scikit-learn.org/stable/modules/generated/sklearn.tree.ExtraTreeClassifier.html) - [ExtraTreeRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.tree.ExtraTreeRegressor.html) - [export\_graphviz](https://scikit-learn.org/stable/modules/generated/sklearn.tree.export_graphviz.html) - [export\_text](https://scikit-learn.org/stable/modules/generated/sklearn.tree.export_text.html) - [plot\_tree](https://scikit-learn.org/stable/modules/generated/sklearn.tree.plot_tree.html) - [sklearn.utils](https://scikit-learn.org/stable/api/sklearn.utils.html) - [Bunch](https://scikit-learn.org/stable/modules/generated/sklearn.utils.Bunch.html) - [\_safe\_indexing](https://scikit-learn.org/stable/modules/generated/sklearn.utils._safe_indexing.html) - [as\_float\_array](https://scikit-learn.org/stable/modules/generated/sklearn.utils.as_float_array.html) - [assert\_all\_finite](https://scikit-learn.org/stable/modules/generated/sklearn.utils.assert_all_finite.html) - [deprecated](https://scikit-learn.org/stable/modules/generated/sklearn.utils.deprecated.html) - [estimator\_html\_repr](https://scikit-learn.org/stable/modules/generated/sklearn.utils.estimator_html_repr.html) - [gen\_batches](https://scikit-learn.org/stable/modules/generated/sklearn.utils.gen_batches.html) - [gen\_even\_slices](https://scikit-learn.org/stable/modules/generated/sklearn.utils.gen_even_slices.html) - [indexable](https://scikit-learn.org/stable/modules/generated/sklearn.utils.indexable.html) - [murmurhash3\_32](https://scikit-learn.org/stable/modules/generated/sklearn.utils.murmurhash3_32.html) - [resample](https://scikit-learn.org/stable/modules/generated/sklearn.utils.resample.html) - [safe\_mask](https://scikit-learn.org/stable/modules/generated/sklearn.utils.safe_mask.html) - [safe\_sqr](https://scikit-learn.org/stable/modules/generated/sklearn.utils.safe_sqr.html) - [shuffle](https://scikit-learn.org/stable/modules/generated/sklearn.utils.shuffle.html) - [Tags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.Tags.html) - [InputTags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.InputTags.html) - [TargetTags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.TargetTags.html) - [ClassifierTags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.ClassifierTags.html) - [RegressorTags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.RegressorTags.html) - [TransformerTags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.TransformerTags.html) - [get\_tags](https://scikit-learn.org/stable/modules/generated/sklearn.utils.get_tags.html) - [check\_X\_y](https://scikit-learn.org/stable/modules/generated/sklearn.utils.check_X_y.html) - [check\_array](https://scikit-learn.org/stable/modules/generated/sklearn.utils.check_array.html) - [check\_consistent\_length](https://scikit-learn.org/stable/modules/generated/sklearn.utils.check_consistent_length.html) - [check\_random\_state](https://scikit-learn.org/stable/modules/generated/sklearn.utils.check_random_state.html) - [check\_scalar](https://scikit-learn.org/stable/modules/generated/sklearn.utils.check_scalar.html) - [check\_is\_fitted](https://scikit-learn.org/stable/modules/generated/sklearn.utils.validation.check_is_fitted.html) - [check\_memory](https://scikit-learn.org/stable/modules/generated/sklearn.utils.validation.check_memory.html) - [check\_symmetric](https://scikit-learn.org/stable/modules/generated/sklearn.utils.validation.check_symmetric.html) - [column\_or\_1d](https://scikit-learn.org/stable/modules/generated/sklearn.utils.validation.column_or_1d.html) - [has\_fit\_parameter](https://scikit-learn.org/stable/modules/generated/sklearn.utils.validation.has_fit_parameter.html) - [validate\_data](https://scikit-learn.org/stable/modules/generated/sklearn.utils.validation.validate_data.html) - [available\_if](https://scikit-learn.org/stable/modules/generated/sklearn.utils.metaestimators.available_if.html) - [compute\_class\_weight](https://scikit-learn.org/stable/modules/generated/sklearn.utils.class_weight.compute_class_weight.html) - [compute\_sample\_weight](https://scikit-learn.org/stable/modules/generated/sklearn.utils.class_weight.compute_sample_weight.html) - [is\_multilabel](https://scikit-learn.org/stable/modules/generated/sklearn.utils.multiclass.is_multilabel.html) - [type\_of\_target](https://scikit-learn.org/stable/modules/generated/sklearn.utils.multiclass.type_of_target.html) - [unique\_labels](https://scikit-learn.org/stable/modules/generated/sklearn.utils.multiclass.unique_labels.html) - [density](https://scikit-learn.org/stable/modules/generated/sklearn.utils.extmath.density.html) - [fast\_logdet](https://scikit-learn.org/stable/modules/generated/sklearn.utils.extmath.fast_logdet.html) - [randomized\_range\_finder](https://scikit-learn.org/stable/modules/generated/sklearn.utils.extmath.randomized_range_finder.html) - [randomized\_svd](https://scikit-learn.org/stable/modules/generated/sklearn.utils.extmath.randomized_svd.html) - [safe\_sparse\_dot](https://scikit-learn.org/stable/modules/generated/sklearn.utils.extmath.safe_sparse_dot.html) - [weighted\_mode](https://scikit-learn.org/stable/modules/generated/sklearn.utils.extmath.weighted_mode.html) - [incr\_mean\_variance\_axis](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.incr_mean_variance_axis.html) - [inplace\_column\_scale](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.inplace_column_scale.html) - [inplace\_csr\_column\_scale](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.inplace_csr_column_scale.html) - [inplace\_row\_scale](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.inplace_row_scale.html) - [inplace\_swap\_column](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.inplace_swap_column.html) - [inplace\_swap\_row](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.inplace_swap_row.html) - [mean\_variance\_axis](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs.mean_variance_axis.html) - [inplace\_csr\_row\_normalize\_l1](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs_fast.inplace_csr_row_normalize_l1.html) - [inplace\_csr\_row\_normalize\_l2](https://scikit-learn.org/stable/modules/generated/sklearn.utils.sparsefuncs_fast.inplace_csr_row_normalize_l2.html) - [single\_source\_shortest\_path\_length](https://scikit-learn.org/stable/modules/generated/sklearn.utils.graph.single_source_shortest_path_length.html) - [sample\_without\_replacement](https://scikit-learn.org/stable/modules/generated/sklearn.utils.random.sample_without_replacement.html) - [min\_pos](https://scikit-learn.org/stable/modules/generated/sklearn.utils.arrayfuncs.min_pos.html) - [MetadataRequest](https://scikit-learn.org/stable/modules/generated/sklearn.utils.metadata_routing.MetadataRequest.html) - [MetadataRouter](https://scikit-learn.org/stable/modules/generated/sklearn.utils.metadata_routing.MetadataRouter.html) - [MethodMapping](https://scikit-learn.org/stable/modules/generated/sklearn.utils.metadata_routing.MethodMapping.html) - [get\_routing\_for\_object](https://scikit-learn.org/stable/modules/generated/sklearn.utils.metadata_routing.get_routing_for_object.html) - [process\_routing](https://scikit-learn.org/stable/modules/generated/sklearn.utils.metadata_routing.process_routing.html) - [all\_displays](https://scikit-learn.org/stable/modules/generated/sklearn.utils.discovery.all_displays.html) - [all\_estimators](https://scikit-learn.org/stable/modules/generated/sklearn.utils.discovery.all_estimators.html) - [all\_functions](https://scikit-learn.org/stable/modules/generated/sklearn.utils.discovery.all_functions.html) - [check\_estimator](https://scikit-learn.org/stable/modules/generated/sklearn.utils.estimator_checks.check_estimator.html) - [parametrize\_with\_checks](https://scikit-learn.org/stable/modules/generated/sklearn.utils.estimator_checks.parametrize_with_checks.html) - [estimator\_checks\_generator](https://scikit-learn.org/stable/modules/generated/sklearn.utils.estimator_checks.estimator_checks_generator.html) - [Parallel](https://scikit-learn.org/stable/modules/generated/sklearn.utils.parallel.Parallel.html) - [delayed](https://scikit-learn.org/stable/modules/generated/sklearn.utils.parallel.delayed.html) - [API Reference](https://scikit-learn.org/stable/api/index.html) - [sklearn.metrics](https://scikit-learn.org/stable/api/sklearn.metrics.html) - ndcg\_score # ndcg\_score[\#](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html#ndcg-score "Link to this heading") sklearn.metrics.ndcg\_score(*y\_true*, *y\_score*, *\**, *k\=None*, *sample\_weight\=None*, *ignore\_ties\=False*)[\[source\]](https://github.com/scikit-learn/scikit-learn/blob/fe2edb3cd/sklearn/metrics/_ranking.py#L1888)[\#](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html#sklearn.metrics.ndcg_score "Link to this definition") Compute Normalized Discounted Cumulative Gain. Sum the true scores ranked in the order induced by the predicted scores, after applying a logarithmic discount. Then divide by the best possible score (Ideal DCG, obtained for a perfect ranking) to obtain a score between 0 and 1. This ranking metric returns a high value if true labels are ranked high by `y_score`. Parameters: **y\_true**array-like of shape (n\_samples, n\_labels) True targets of multilabel classification, or true scores of entities to be ranked. Negative values in `y_true` may result in an output that is not between 0 and 1. **y\_score**array-like of shape (n\_samples, n\_labels) Target scores, can either be probability estimates, confidence values, or non-thresholded measure of decisions (as returned by “decision\_function” on some classifiers). **k**int, default=None Only consider the highest k scores in the ranking. If `None`, use all outputs. **sample\_weight**array-like of shape (n\_samples,), default=None Sample weights. If `None`, all samples are given the same weight. **ignore\_ties**bool, default=False Assume that there are no ties in y\_score (which is likely to be the case if y\_score is continuous) for efficiency gains. Returns: **normalized\_discounted\_cumulative\_gain**float in \[0., 1.\] The averaged NDCG scores for all samples. See also [`dcg_score`](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.dcg_score.html#sklearn.metrics.dcg_score "sklearn.metrics.dcg_score") Discounted Cumulative Gain (not normalized). References [Wikipedia entry for Discounted Cumulative Gain](https://en.wikipedia.org/wiki/Discounted_cumulative_gain) Jarvelin, K., & Kekalainen, J. (2002). Cumulated gain-based evaluation of IR techniques. ACM Transactions on Information Systems (TOIS), 20(4), 422-446. Wang, Y., Wang, L., Li, Y., He, D., Chen, W., & Liu, T. Y. (2013, May). A theoretical analysis of NDCG ranking measures. In Proceedings of the 26th Annual Conference on Learning Theory (COLT 2013) McSherry, F., & Najork, M. (2008, March). Computing information retrieval performance measures efficiently in the presence of tied scores. In European conference on information retrieval (pp. 414-421). Springer, Berlin, Heidelberg. Examples ``` >>> import numpy as np >>> from sklearn.metrics import ndcg_score >>> # we have ground-truth relevance of some answers to a query: >>> true_relevance = np.asarray([[10, 0, 0, 1, 5]]) >>> # we predict some scores (relevance) for the answers >>> scores = np.asarray([[.1, .2, .3, 4, 70]]) >>> ndcg_score(true_relevance, scores) 0.69 >>> scores = np.asarray([[.05, 1.1, 1., .5, .0]]) >>> ndcg_score(true_relevance, scores) 0.49 >>> # we can set k to truncate the sum; only top k answers contribute. >>> ndcg_score(true_relevance, scores, k=4) 0.35 >>> # the normalization takes k into account so a perfect answer >>> # would still get 1.0 >>> ndcg_score(true_relevance, true_relevance, k=4) 1.0... >>> # now we have some ties in our prediction >>> scores = np.asarray([[1, 0, 0, 0, 1]]) >>> # by default ties are averaged, so here we get the average (normalized) >>> # true relevance of our top predictions: (10 / 10 + 5 / 10) / 2 = .75 >>> ndcg_score(true_relevance, scores, k=1) 0.75 >>> # we can choose to ignore ties for faster results, but only >>> # if we know there aren't ties in our scores, otherwise we get >>> # wrong results: >>> ndcg_score(true_relevance, ... scores, k=1, ignore_ties=True) 0.5... ``` [previous multilabel\_confusion\_matrix](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.multilabel_confusion_matrix.html "previous page") [next precision\_recall\_curve](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.precision_recall_curve.html "next page") On this page - [`ndcg_score`](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html#sklearn.metrics.ndcg_score) ### This Page - [Show Source](https://scikit-learn.org/stable/_sources/modules/generated/sklearn.metrics.ndcg_score.rst.txt) © Copyright 2007 - 2026, scikit-learn developers (BSD License).
Readable Markdown
sklearn.metrics.ndcg\_score(*y\_true*, *y\_score*, *\**, *k\=None*, *sample\_weight\=None*, *ignore\_ties\=False*)[\[source\]](https://github.com/scikit-learn/scikit-learn/blob/fe2edb3cd/sklearn/metrics/_ranking.py#L1888)[\#](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.ndcg_score.html#sklearn.metrics.ndcg_score "Link to this definition") Compute Normalized Discounted Cumulative Gain. Sum the true scores ranked in the order induced by the predicted scores, after applying a logarithmic discount. Then divide by the best possible score (Ideal DCG, obtained for a perfect ranking) to obtain a score between 0 and 1. This ranking metric returns a high value if true labels are ranked high by `y_score`. Parameters: **y\_true**array-like of shape (n\_samples, n\_labels) True targets of multilabel classification, or true scores of entities to be ranked. Negative values in `y_true` may result in an output that is not between 0 and 1. **y\_score**array-like of shape (n\_samples, n\_labels) Target scores, can either be probability estimates, confidence values, or non-thresholded measure of decisions (as returned by “decision\_function” on some classifiers). **k**int, default=None Only consider the highest k scores in the ranking. If `None`, use all outputs. **sample\_weight**array-like of shape (n\_samples,), default=None Sample weights. If `None`, all samples are given the same weight. **ignore\_ties**bool, default=False Assume that there are no ties in y\_score (which is likely to be the case if y\_score is continuous) for efficiency gains. Returns: **normalized\_discounted\_cumulative\_gain**float in \[0., 1.\] The averaged NDCG scores for all samples. See also [`dcg_score`](https://scikit-learn.org/stable/modules/generated/sklearn.metrics.dcg_score.html#sklearn.metrics.dcg_score "sklearn.metrics.dcg_score") Discounted Cumulative Gain (not normalized). References [Wikipedia entry for Discounted Cumulative Gain](https://en.wikipedia.org/wiki/Discounted_cumulative_gain) Jarvelin, K., & Kekalainen, J. (2002). Cumulated gain-based evaluation of IR techniques. ACM Transactions on Information Systems (TOIS), 20(4), 422-446. Wang, Y., Wang, L., Li, Y., He, D., Chen, W., & Liu, T. Y. (2013, May). A theoretical analysis of NDCG ranking measures. In Proceedings of the 26th Annual Conference on Learning Theory (COLT 2013) McSherry, F., & Najork, M. (2008, March). Computing information retrieval performance measures efficiently in the presence of tied scores. In European conference on information retrieval (pp. 414-421). Springer, Berlin, Heidelberg. Examples ``` >>> import numpy as np >>> from sklearn.metrics import ndcg_score >>> # we have ground-truth relevance of some answers to a query: >>> true_relevance = np.asarray([[10, 0, 0, 1, 5]]) >>> # we predict some scores (relevance) for the answers >>> scores = np.asarray([[.1, .2, .3, 4, 70]]) >>> ndcg_score(true_relevance, scores) 0.69 >>> scores = np.asarray([[.05, 1.1, 1., .5, .0]]) >>> ndcg_score(true_relevance, scores) 0.49 >>> # we can set k to truncate the sum; only top k answers contribute. >>> ndcg_score(true_relevance, scores, k=4) 0.35 >>> # the normalization takes k into account so a perfect answer >>> # would still get 1.0 >>> ndcg_score(true_relevance, true_relevance, k=4) 1.0... >>> # now we have some ties in our prediction >>> scores = np.asarray([[1, 0, 0, 0, 1]]) >>> # by default ties are averaged, so here we get the average (normalized) >>> # true relevance of our top predictions: (10 / 10 + 5 / 10) / 2 = .75 >>> ndcg_score(true_relevance, scores, k=1) 0.75 >>> # we can choose to ignore ties for faster results, but only >>> # if we know there aren't ties in our scores, otherwise we get >>> # wrong results: >>> ndcg_score(true_relevance, ... scores, k=1, ignore_ties=True) 0.5... ```
Shard148 (laksa)
Root Hash6052685795207125548
Unparsed URLorg,scikit-learn!/stable/modules/generated/sklearn.metrics.ndcg_score.html s443