Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

calculate quantiles python

>>> np.percentile(df.time_diff, 25)  # Q1
0.48333300000000001

>>> np.percentile(df.time_diff, 50)  # Q2 (median)
0.5

>>> np.percentile(df.time_diff, 75)  # Q3
0.51666699999999999
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #calculate #quantiles #python
ADD COMMENT
Topic
Name
7+6 =