Suppose, we wanted to find a point where 70% of samples are above and 30% are below and how are we going to find it. These types of points are called a percentile.
The Nth percentile is called at the point where the N% samples are below.
Percentiles are useful measurements because they show us where a specific value falls within the larger dataset.
Example:
import numpy as np
arr = np.array([ 2, 6, 14, 4, 3, 9, 1, 11, 4, 2, 8])
thirtieth_percentile = np.percentile(arr, 30)
seventieth_percentile = np.percentile(arr, 70)
fourteith_percentile = np.percentile(arr, 40)
print(thirtieth_percentile)
print(seventieth_percentile)
print(fourteith_percentile)
Example:
3.0
8.0
4.0
Some percentiles have specific names:
The 25th percentile is called the first quartile.
The 50th percentile is called the median.
The 75th percentile is called the third quartile.
The difference between the first and third quartile is a value called the interquartile range.
Example:
d = [1, 2, 3, 4, 4, 4, 6, 6, 7, 8, 8]
Now we can calculate 25th and 75th percentile
np.percentile(d, 25) #prints 3.5
np.percentile(d, 75) #prints 6.5
To find the interquartile range, we subtract the value of the 25th percentile from the value of the 75th:
6.5 - 3.5 = 3
Half of the data will fall within the interquartile range. The interquartile range indicates how to spread out our data. The lower the interquartile range value, the less variation there is in our dataset. The higher the value, the greater the variance.
Trainings :
Data Science Training in Indore | Data Analytics Training in Indore | Python Training in Indore | Blockchain Training in Indore | React JS Training in Indore | Web Development Training in Indore | Full Stack Development Training in Indore |Free Courses and Resource :
Verbal Aptitude | Matplotlib Tutorials | Examples | Interview Questions | Pandas Tutorials | Projects | Interview Questions | OpenCV Tutorials | Projects | Interview Questions | ExpressJS Tutorials | Projects | Interview Questions | Dart | Python Data Structures and Algorithms | Rust Tutorials | Projects | Interview Questions | Aptitude Tests | HackerRank Python | Django | MongoDB Tutorials | Examples | Interview Questions | NumPy Practice Questions | Python Tutorials by CodersDaily | Golang Tutorials | Projects | Interview Questions | React.js Tutorials | Verbal Ability Tutorial | MS Sql Server Tutorials | Examples | Interview Questions | Power BI Tutorials | Projects | Interview Questions | Example Dashboards | Numpy Tutorials | Projects | Interview Questions | Django REST Framework Tutorial | HackerRank C++ Solutions | Tensor Flow | Pandas Practice Questions | Python Practice Questions | C++ Tutorials | Quantitative Ability Tutorial | Javascript | Node.js Tutorials | HackerRank SQL Solutions | HackerRank DSA Solutions | Verbal Aptitude 2 | HackerRank Java Solutions | HTML Tutorial | TCS NQT Mock Test Series | Reasoning Ability Tutorial | CodeChef Python Solutions | HackerRank C Program Solutions | Leetcode Python Solutions | SQL Practice Question | Matplotlib Practice Questions |Interview Questions :
Pandas Tutorials | Projects | Interview Questions | ExpressJS Tutorials | Projects | Interview Questions | Django | Python Tutorials by CodersDaily | Golang Tutorials | Projects | Interview Questions | Numpy Tutorials | Projects | Interview Questions | Django REST Framework Tutorial |Top Colleges in India :
Indian Institute of Technology Bombay | Jaypee University of Engineering and Technology - Guna |