User Tools

Site Tools


b:head_first_statistics:measuring_central_tendency

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
b:head_first_statistics:measuring_central_tendency [2023/09/11 08:18] – [skewedness] hkimscilb:head_first_statistics:measuring_central_tendency [2024/09/09 09:50] (current) – [mean] hkimscil
Line 21: Line 21:
 이것을 우리는 흔히 "무"라고 부른다.  이것을 우리는 흔히 "무"라고 부른다. 
 \begin{equation*} \begin{equation*}
-\mu = \frac{\sum\limits_{i=1}^{n} X_i}{n}+\mu = \frac{\sum\limits_{i=1}^{N} X_i}{N}
 \end{equation*} \end{equation*}
  
Line 31: Line 31:
 \begin{equation*} \begin{equation*}
 \begin{split} \begin{split}
-\mu = \frac{\sum\limits_{}^{} \text{fx}}{\sum{\text{f}}} +\mu = \frac{\sum\limits_{}^{} \text{fx}}{\sum{\text{f.nothing}}} 
     = \frac{1 \text{x} 19 + 3 \text{x} 20 + 1 \text{x} 21}{5}     = \frac{1 \text{x} 19 + 3 \text{x} 20 + 1 \text{x} 21}{5}
 \end{split} \end{split}
Line 43: Line 43:
 ===== skewedness ===== ===== skewedness =====
 <WRAP info> <WRAP info>
 +skewedness: 왜도
 {{skewedness.jpg}} {{skewedness.jpg}}
 </WRAP> </WRAP>
Line 104: Line 105:
 ==== e.g. 1 ==== ==== e.g. 1 ====
  
-quartile 명령어는 r에서는 없다. 대신 quantile을 사용합니다. 둘은 비슷하나 quantile은 4분위 이상의 것을 한다.+quartile 명령어는 r에서는 없다. 대신 quantile을 사용다. 둘은 비슷하나 quantile은 4분위 이상의 것을 한다.
  
 R에서  R에서 
Line 202: Line 203:
  
 </code> </code>
- 
- 
-|value | 1  | 4  | 6  | 8  | 9  | 10  | 11  | 12  | 
-|freq  | 1  | 1  | 2  | 3  | 4  | 4   | 5  | 5   | 
  
 <code> <code>
Line 215: Line 212:
 <code> <code>
 {1, 1, 1, 2, 2, 2, 2, 2, 3, 31, 31, 31, 32, 32, 32, 32, 33, 33, 33} {1, 1, 1, 2, 2, 2, 2, 2, 3, 31, 31, 31, 32, 32, 32, 32, 33, 33, 33}
 +</code>
 +<code>
 +a <- c(1, 1, 1, 2, 2, 2, 2, 3, 3, 31, 31, 32, 32, 32, 32, 33, 33, 33)
 +b <- c(1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 31, 31, 32, 32, 32, 32, 33, 33, 33)
 +c <- c(1, 1, 1, 2, 2, 2, 2, 2, 3, 31, 31, 31, 32, 32, 32, 32, 33, 33, 33)
 +a
 +b
 +c
 +length(a)
 +length(b)
 +length(c)
 +mean(a)
 +mean(b)
 +mean(c)
 +median(a)
 +median(b)
 +median(c)
 +</code>
 +<code>
 +# output 
 +> a <- c(1, 1, 1, 2, 2, 2, 2, 3, 3, 31, 31, 32, 32, 32, 32, 33, 33, 33)
 +> b <- c(1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 31, 31, 32, 32, 32, 32, 33, 33, 33)
 +> c <- c(1, 1, 1, 2, 2, 2, 2, 2, 3, 31, 31, 31, 32, 32, 32, 32, 33, 33, 33)
 +> a
 + [1]  1  1  1  2  2  2  2  3  3 31 31 32 32 32 32 33 33 33
 +> b
 + [1]  1  1  1  2  2  2  2  2  3  3 31 31 32 32 32 32 33 33 33
 +> c
 + [1]  1  1  1  2  2  2  2  2  3 31 31 31 32 32 32 32 33 33 33
 +> length(a)
 +[1] 18
 +> length(b)
 +[1] 19
 +> length(c)
 +[1] 19
 +> mean(a)
 +[1] 17
 +> mean(b)
 +[1] 16.21053
 +> mean(c)
 +[1] 17.68421
 +> median(a)
 +[1] 17
 +> median(b)
 +[1] 3
 +> median(c)
 +[1] 31
 +
 </code> </code>
  
Line 222: Line 267:
 <code> <code>
 ## answer  ## answer 
 +n <- 3+2+2 +3+4+4
 +
 +mean.duckc <- 17
 +median.duckc <- 17
 +tot <- mean.duckc * n  
 +# 2 :: 4 인것은 이미 알고 있음
 +known.sum <- (1*3)+(2*4)+(3*2)+(31*2)
 +tot - known.sum 
 +# 227 = (32*4) + (33*3) 이므로 
 duckc <- c(1,1,1,2,2,2,2,3,3,31,31,32,32,32,32,33,33,33) duckc <- c(1,1,1,2,2,2,2,3,3,31,31,32,32,32,32,33,33,33)
 mean(duckc) mean(duckc)
b/head_first_statistics/measuring_central_tendency.1694387913.txt.gz · Last modified: 2023/09/11 08:18 by hkimscil

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki