Pandas DataFrame: describe() function
DataFrame - describe() function
The describe() function is used to generate descriptive statistics that summarize the central tendency, dispersion and shape of a dataset’s distribution, excluding NaN values.
Syntax:DataFrame.describe(self, percentiles=None, include=None, exclude=None)
Parameters:
Name | Description | Type/Default Value | Required / Optional |
---|---|---|---|
percentiles | The percentiles to include in the output. All should fall between 0 and 1. The default is [.25, .5, .75], which returns the 25th, 50th, and 75th percentiles. | list-like of numbers | Optional |
include | A white list of data types to include in the result. Ignored for Series. Here are the options:
|
'all', list-like of dtypes or None (default) | Optional |
exclude | A black list of data types to omit from the result. Ignored for Series. Here are the options:
|
list-like of dtypes or None (default) | Optional |
Returns: Series or DataFrame
Summary statistics of the Series or Dataframe provided.
Example:
Download the Pandas DataFrame Notebooks from here.
Previous: DataFrame - cumsum() function
Next: DataFrame - diff() function
- New Content published on w3resource:
- HTML-CSS Practical: Exercises, Practice, Solution
- Java Regular Expression: Exercises, Practice, Solution
- Scala Programming Exercises, Practice, Solution
- Python Itertools exercises
- Python Numpy exercises
- Python GeoPy Package exercises
- Python Pandas exercises
- Python nltk exercises
- Python BeautifulSoup exercises
- Form Template
- Composer - PHP Package Manager
- PHPUnit - PHP Testing
- Laravel - PHP Framework
- Angular - JavaScript Framework
- Vue - JavaScript Framework
- Jest - JavaScript Testing Framework