ā¹ļø Skipped - page is already crawled
| Filter | Status | Condition | Details |
|---|---|---|---|
| HTTP status | PASS | download_http_code = 200 | HTTP 200 |
| Age cutoff | PASS | download_stamp > now() - 6 MONTH | 0 months ago |
| History drop | PASS | isNull(history_drop_reason) | No drop reason |
| Spam/ban | PASS | fh_dont_index != 1 AND ml_spam_score = 0 | ml_spam_score=0 |
| Canonical | PASS | meta_canonical IS NULL OR = '' OR = src_unparsed | Not set |
| Property | Value |
|---|---|
| URL | https://catboost.ai/docs/en/features/feature-importances-calculation |
| Last Crawled | 2026-04-16 10:05:26 (17 hours ago) |
| First Indexed | 2024-11-14 16:20:31 (1 year ago) |
| HTTP Status Code | 200 |
| Meta Title | Feature importances | CatBoost |
| Meta Description | CatBoost provides different types of feature importance calculation: Feature importance calculation type Implementations. |
| Meta Canonical | null |
| Boilerpipe Text | CatBoost provides different types of feature importance calculation:
Feature importance calculation type
Implementations
The most important features in the formula
-
PredictionValuesChange
-
LossFunctionChange
-
InternalFeatureImportance
The contribution of each feature to the formula
ShapValues
The features that work well together
-
Interaction
-
InternalInteraction
Choose the implementation for more details.
Python package
Use one of the following methods:
Use theĀ feature_importances_ attribute.
Use one of the following methods to calculate the feature importances after model training:
Class
Description
CatBoost
get_feature_importance
CatBoostClassifier
get_feature_importance
CatBoostRegressor
get_feature_importance
These methods calculate and return theĀ
feature importances
.
R package
Use one of the following methods:
Use theĀ
feature_importances
attribute
to get the feature importances.
Use one of the following methods to calculate the feature importances after model training:
Method
Description
catboost.get_feature_importance
Calculate the
feature importances
(
Feature importance
andĀ
Feature interaction strength
).
Command-line version
Use the following commandĀ to calculate the feature importances during model training:
Command
Command keys
Key description
catboost fit
--fstr-file
The name of the resulting file that containsĀ
regular feature importance
data (see
Feature importance
).
Set the required file name for further feature importance analysis.
--fstr-internal-file
The name of the resulting file that containsĀ
internal feature importance
data (see
Feature importance
).
Set the required file name for further internal feature importance analysis.
Use the following command to calculate the feature importances after model training:
Command
Purpose
catboost fstr
Calculate feature importances.
Model analysis |
| Markdown | [](https://catboost.ai/ "CatBoost")
- Installation
- [Overview](https://catboost.ai/docs/en/features/en/concepts/installation)
- Python package installation
- CatBoost for Apache Spark installation
- R package installation
- Command-line version binary
- Build from source
- Key Features
- [Training](https://catboost.ai/docs/en/features/en/features/training)
- [Training on GPU](https://catboost.ai/docs/en/features/en/features/training-on-gpu)
- [Regular prediction](https://catboost.ai/docs/en/features/en/features/prediction)
- [Staged prediction](https://catboost.ai/docs/en/features/en/features/staged-prediction)
- [Cross-validation](https://catboost.ai/docs/en/features/en/features/cross-validation)
- [Feature importances](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation)
- [User-defined metrics](https://catboost.ai/docs/en/features/en/features/custom-loss-functions)
- [Using the overfitting detector](https://catboost.ai/docs/en/features/en/features/overfitting-detector-desc)
- [Export a model to CoreML](https://catboost.ai/docs/en/features/en/features/export-model-to-core-ml)
- [Pre-trained data](https://catboost.ai/docs/en/features/en/features/proceed-training)
- [Calculate metrics](https://catboost.ai/docs/en/features/en/features/eval-metrics)
- [Categorical features](https://catboost.ai/docs/en/features/en/features/categorical-features)
- [Text features](https://catboost.ai/docs/en/features/en/features/text-features)
- [Embeddings features](https://catboost.ai/docs/en/features/en/features/embeddings-features)
- [Aggregated graph features](https://catboost.ai/docs/en/features/en/features/graph-aggregated-features)
- [Implemented metrics](https://catboost.ai/docs/en/features/en/features/loss-functions-desc)
- [Export a model to Python or C++](https://catboost.ai/docs/en/features/en/features/export-model-to-python)
- [Export a model to JSON](https://catboost.ai/docs/en/features/en/features/export-model-to-json)
- [Object importances](https://catboost.ai/docs/en/features/en/features/object-importances-calcution)
- Training parameters
- Python package
- CatBoost for Apache Spark
- R package
- Command-line version
- Applying models
- Objectives and metrics
- Model analysis
- Data format description
- [Parameter tuning](https://catboost.ai/docs/en/features/en/concepts/parameter-tuning)
- [Speeding up the training](https://catboost.ai/docs/en/features/en/concepts/speed-up-training)
- Data visualization
- Algorithm details
- [FAQ](https://catboost.ai/docs/en/features/en/concepts/faq)
- Educational materials
- [Development and contributions](https://catboost.ai/docs/en/features/en/concepts/development-and-contributions)
- [Contacts](https://catboost.ai/docs/en/features/en/concepts/contacts)
Feature importances
## In this article:
- [Python package](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#python-package)
- [R package](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#r-package)
- [Command-line version](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#command-line-version)
- [Related information](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#related-information)
1. Key Features
2. Feature importances
# Feature importances
- [Python package](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#python-package)
- [R package](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#r-package)
- [Command-line version](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#command-line-version)
- [Related information](https://catboost.ai/docs/en/features/en/features/feature-importances-calculation#related-information)
CatBoost provides different types of feature importance calculation:
| Feature importance calculation type | Implementations |
|---|---|
| The most important features in the formula | \- [PredictionValuesChange](https://catboost.ai/docs/en/features/en/concepts/fstr#regular-feature-importance) - [LossFunctionChange](https://catboost.ai/docs/en/features/en/concepts/fstr#regular-feature-importances__lossfunctionchange) - [InternalFeatureImportance](https://catboost.ai/docs/en/features/en/concepts/fstr#internal-feature-importance) |
| The contribution of each feature to the formula | [ShapValues](https://catboost.ai/docs/en/features/en/concepts/shap-values) |
| The features that work well together | \- [Interaction](https://catboost.ai/docs/en/features/en/concepts/feature-interaction#feature-interaction-strength) \- [InternalInteraction](https://catboost.ai/docs/en/features/en/concepts/feature-interaction#internal-feature-interaction-strength) |
Choose the implementation for more details.
## Python package
Use one of the following methods:
- Use the feature\_importances\_ attribute.
- Use one of the following methods to calculate the feature importances after model training:
| Class | Description |
|---|---|
| [CatBoost](https://catboost.ai/docs/en/features/en/concepts/python-reference_catboost) | [get\_feature\_importance](https://catboost.ai/docs/en/features/en/concepts/python-reference_catboost_get_feature_importance) |
| [CatBoostClassifier](https://catboost.ai/docs/en/features/en/concepts/python-reference_catboostclassifier) | [get\_feature\_importance](https://catboost.ai/docs/en/features/en/concepts/python-reference_catboostclassifier_get_feature_importance) |
| [CatBoostRegressor](https://catboost.ai/docs/en/features/en/concepts/python-reference_catboostregressor) | [get\_feature\_importance](https://catboost.ai/docs/en/features/en/concepts/python-reference_catboostregressor_get_feature_importance) |
These methods calculate and return the [feature importances](https://catboost.ai/docs/en/features/en/concepts/fstr).
## R package
Use one of the following methods:
- Use the `feature_importances`[attribute](https://catboost.ai/docs/en/features/en/concepts/r-reference#attributes) to get the feature importances.
- Use one of the following methods to calculate the feature importances after model training:
| Method | Description |
|---|---|
| [catboost.get\_feature\_importance](https://catboost.ai/docs/en/features/en/concepts/r-reference_catboost-get_feature_importance) | Calculate the [feature importances](https://catboost.ai/docs/en/features/en/concepts/fstr) ([Feature importance](https://catboost.ai/docs/en/features/en/concepts/output-data_feature-analysis_feature-importance) and [Feature interaction strength](https://catboost.ai/docs/en/features/en/concepts/output-data_feature-analysis_feature-interaction-strength)). |
## Command-line version
Use the following command to calculate the feature importances during model training:
| Command | Command keys | Key description |
|---|---|---|
| [catboost fit](https://catboost.ai/docs/en/features/en/references/training-parameters/) | `--fstr-file` | The name of the resulting file that contains [regular feature importance](https://catboost.ai/docs/en/features/en/concepts/output-data_feature-analysis_feature-importance#per-feature-importance) data (see [Feature importance](https://catboost.ai/docs/en/features/en/concepts/fstr)). Set the required file name for further feature importance analysis. |
| | `--fstr-internal-file` | The name of the resulting file that contains [internal feature importance](https://catboost.ai/docs/en/features/en/concepts/output-data_feature-analysis_feature-importance#internal-feature-importance) data (see [Feature importance](https://catboost.ai/docs/en/features/en/concepts/fstr)). Set the required file name for further internal feature importance analysis. |
Use the following command to calculate the feature importances after model training:
| Command | Purpose |
|---|---|
| [catboost fstr](https://catboost.ai/docs/en/features/en/concepts/cli-reference_fstr-calc) | Calculate feature importances. |
## Related information
[Model analysis](https://catboost.ai/docs/en/features/en/concepts/model-analysis)
### Was the article helpful?
Yes
No
Previous
[Cross-validation](https://catboost.ai/docs/en/features/en/features/cross-validation)
Next
[User-defined metrics](https://catboost.ai/docs/en/features/en/features/custom-loss-functions)
 |
| Readable Markdown | CatBoost provides different types of feature importance calculation:
| Feature importance calculation type | Implementations |
|---|---|
| The most important features in the formula | \- [PredictionValuesChange](https://catboost.ai/docs/en/concepts/fstr#regular-feature-importance) - [LossFunctionChange](https://catboost.ai/docs/en/concepts/fstr#regular-feature-importances__lossfunctionchange) - [InternalFeatureImportance](https://catboost.ai/docs/en/concepts/fstr#internal-feature-importance) |
| The contribution of each feature to the formula | [ShapValues](https://catboost.ai/docs/en/concepts/shap-values) |
| The features that work well together | \- [Interaction](https://catboost.ai/docs/en/concepts/feature-interaction#feature-interaction-strength) \- [InternalInteraction](https://catboost.ai/docs/en/concepts/feature-interaction#internal-feature-interaction-strength) |
Choose the implementation for more details.
## Python package
Use one of the following methods:
- Use the feature\_importances\_ attribute.
- Use one of the following methods to calculate the feature importances after model training:
| Class | Description |
|---|---|
| [CatBoost](https://catboost.ai/docs/en/concepts/python-reference_catboost) | [get\_feature\_importance](https://catboost.ai/docs/en/concepts/python-reference_catboost_get_feature_importance) |
| [CatBoostClassifier](https://catboost.ai/docs/en/concepts/python-reference_catboostclassifier) | [get\_feature\_importance](https://catboost.ai/docs/en/concepts/python-reference_catboostclassifier_get_feature_importance) |
| [CatBoostRegressor](https://catboost.ai/docs/en/concepts/python-reference_catboostregressor) | [get\_feature\_importance](https://catboost.ai/docs/en/concepts/python-reference_catboostregressor_get_feature_importance) |
These methods calculate and return the [feature importances](https://catboost.ai/docs/en/concepts/fstr).
## R package
Use one of the following methods:
- Use the `feature_importances`[attribute](https://catboost.ai/docs/en/concepts/r-reference#attributes) to get the feature importances.
- Use one of the following methods to calculate the feature importances after model training:
| Method | Description |
|---|---|
| [catboost.get\_feature\_importance](https://catboost.ai/docs/en/concepts/r-reference_catboost-get_feature_importance) | Calculate the [feature importances](https://catboost.ai/docs/en/concepts/fstr) ([Feature importance](https://catboost.ai/docs/en/concepts/output-data_feature-analysis_feature-importance) and [Feature interaction strength](https://catboost.ai/docs/en/concepts/output-data_feature-analysis_feature-interaction-strength)). |
## Command-line version
Use the following command to calculate the feature importances during model training:
| Command | Command keys | Key description |
|---|---|---|
| [catboost fit](https://catboost.ai/docs/en/references/training-parameters/) | `--fstr-file` | The name of the resulting file that contains [regular feature importance](https://catboost.ai/docs/en/concepts/output-data_feature-analysis_feature-importance#per-feature-importance) data (see [Feature importance](https://catboost.ai/docs/en/concepts/fstr)). Set the required file name for further feature importance analysis. |
| | `--fstr-internal-file` | The name of the resulting file that contains [internal feature importance](https://catboost.ai/docs/en/concepts/output-data_feature-analysis_feature-importance#internal-feature-importance) data (see [Feature importance](https://catboost.ai/docs/en/concepts/fstr)). Set the required file name for further internal feature importance analysis. |
Use the following command to calculate the feature importances after model training:
| Command | Purpose |
|---|---|
| [catboost fstr](https://catboost.ai/docs/en/concepts/cli-reference_fstr-calc) | Calculate feature importances. |
[Model analysis](https://catboost.ai/docs/en/concepts/model-analysis) |
| Shard | 169 (laksa) |
| Root Hash | 17435841955170310369 |
| Unparsed URL | ai,catboost!/docs/en/features/feature-importances-calculation s443 |