{statics} Kvartil (quartiles) why I didnt get right solution ?

  • Thread starter Thread starter artiny
  • Start date Start date
  • Tags Tags
    Statics
Click For Summary
SUMMARY

The discussion centers on calculating quartiles using MATLAB for the vector x = [5, 8, 10, 11, 137]. The user initially miscalculated the third quartile (Q3) as 11 and the first quartile (Q1) as 8. The correct approach involves interpolation, specifically using the MATLAB function for quantiles, which reveals that Q1 is actually 7.25 when calculated correctly. This highlights the importance of understanding interpolation in statistical calculations.

PREREQUISITES
  • Understanding of quartiles and their significance in statistics
  • Familiarity with MATLAB programming and its statistical functions
  • Basic knowledge of interpolation methods
  • Ability to work with vectors in MATLAB
NEXT STEPS
  • Learn how to use the MATLAB function 'quantile' for quartile calculations
  • Study interpolation techniques in statistics
  • Explore MATLAB's documentation on statistical functions
  • Practice calculating quartiles with different datasets in MATLAB
USEFUL FOR

Students, data analysts, and anyone learning statistical methods using MATLAB, particularly those focused on quartile calculations and interpolation techniques.

artiny
Messages
6
Reaction score
0

Homework Statement



On this vector I didnt get the right answer:

x = [ 5 8 10 11 137 ] [/B]
q3: i = (p/100)*n = (75/100)*5 = 3.75 >> 4th in vector is 11
q1: i = (25/100)*5 = 1.25 >> 2nd is 8

in MATLAB is solution
Capture.PNG

Homework Equations

The Attempt at a Solution

 
Physics news on Phys.org
Never seen this concept before, but from a little reading at http://au.mathworks.com/help/stats/quantiles-and-percentiles.html it seems that the vector is interpreted as:
1/10 are <= 5
3/10 are <= 8,
5/10 are <= 10
etc.
For the first quartile, we want find how many are <= 0.25. This is done by interpolation between1/10 and 3/10. 0.25 is positioned (0.25-0.1)/(0.3-0.1) along that interval, so gets that share of (8-5):
5 + (8-5)*(0.25-0.1)/(0.3-0.1) = 7.25.
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 19 ·
Replies
19
Views
3K
Replies
1
Views
3K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 11 ·
Replies
11
Views
3K
Replies
13
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 12 ·
Replies
12
Views
3K