A Estatistica Basica
Por: mylah • 30/6/2016 • Trabalho acadêmico • 1.497 Palavras (6 Páginas) • 424 Visualizações
UNIVERSIDADE FEDERAL DE ALAGOAS
CAMPUS ARAPIRACA
TRABALHO DE ESTATÍSTICA
Prof: Odair Barbosa
Alunos: Camila Regina dos Santos, Tiago Antônio
Questão 1
> x<-c(151,152,154,155,158,159,159,160,161,161,161,162,163,
+ 163,163,164,165,165, 165,166,166,166,166,167,167,167,167,167,168,
+ 168,168,168,168,168,168,168,168,168,169,169,169 ,169 ,169,169,
+ 169,170,170,170,170,170,170,170,171,171,171,171,172,172,172,173,
+ 173,173,174,174,174,175,175,175,175,176,176,176,176,177,177,177,
+ 177,178 ,178,178,179,179,180,180,180,180,181,181,181,182,182,182,
+ 183,184,185,186,187 ,188 ,190,190)
> diff(range(x))
[1] 39
> r=sqrt(100)
> r
[1] 10
> h=(39/10)
> h
[1] 3.9
> n=fdt(x,start=151,end=191,h=4)
> n
Class limits f rf rf(%) cf cf(%)
[151,155) 3 0.03 3 3 3
[155,159) 2 0.02 2 5 5
[159,163) 7 0.07 7 12 12
[163,167) 11 0.11 11 23 23
[167,171) 29 0.29 29 52 52
[171,175) 13 0.13 13 65 65
[175,179) 15 0.15 15 80 80
[179,183) 12 0.12 12 92 92
[183,187) 4 0.04 4 96 96
[187,191) 4 0.04 4 100 100
> fa=table(x)
> fa
x
151 152 154 155 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176
1 1 1 1 1 2 1 3 1 3 1 3 4 5 10 7 7 4 3 3 3 4 4
177 178 179 180 181 182 183 184 185 186 187 188 190
4 3 2 4 3 3 1 1 1 1 1 1 2
> hist(x, main = "Sal. dos Funcionários", xlab = "Salário", ylab = "Funcionários", col = "pink")
> h=hist(x, main = "Sal. dos Funcionários", xlab = "Salário", ylab = "Funcionários", col = "pink")
> lines(c(min(h$breaks), h$mids, max(h$breaks)), c(0,h$counts, 0), type = "l")
[pic 1]
Questão 2
> amostra <- c(2,0,0,4,3,0,0,1,0,0,1,1,2,1,1,1,1,1,1,0,0,0,3,0,0,0,2,0,0,1,1,2,0,2,0,0,0,0,0,0,0,0,0,0,0,0,1,0)
> sort(amostra)
[1] 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2
[45] 2 3 3 4
> x=fdt(amostra)
> x
Class limits f rf rf(%) cf cf(%)
[0,0.58) 28 0.58 58.33 28 58.33
[0.58,1.2) 12 0.25 25.00 40 83.33
[1.2,1.7) 0 0.00 0.00 40 83.33
[1.7,2.3) 5 0.10 10.42 45 93.75
[2.3,2.9) 0 0.00 0.00 45 93.75
[2.9,3.5) 2 0.04 4.17 47 97.92
[3.5,4) 1 0.02 2.08 48 100.00
Questão 3
> amostra = c(10 ,15 ,25 ,21 ,6 ,23 ,15 ,21 ,26 ,32 ,9 ,14 ,19 ,20 ,32 ,18 ,16 ,26 ,24 ,20 ,7 ,18 ,17 ,28 ,35,22 ,19 ,39 ,18 ,21 ,15 ,18 ,22 ,20 ,25 ,28 ,30 ,1,6 ,12 ,20)
> x=fdt(amostra)
> x
Class limits f rf rf(%) cf cf(%)
[0.99,6.5) 3 0.07 7.32 3 7.32
[6.5,12) 3 0.07 7.32 6 14.63
[12,17) 7 0.17 17.07 13 31.71
[17,23) 15 0.37 36.59 28 68.29
[23,28) 8 0.20 19.51 36 87.80
[28,34) 3 0.07 7.32 39 95.12
[34,39) 2 0.05 4.88 41 100.00
Questão 4
> amostra = c(33 ,33 ,35 ,35 ,39 ,41 ,41 ,42 ,45 ,45 ,47 ,48 ,50 ,52 ,53 ,54 ,55 ,55 ,56 ,57,59 ,60 ,61 ,64 ,65 ,65 ,65 ,66 ,67,68 ,68 ,69 ,71 ,73 ,73 ,73 ,74 ,74 ,76 ,77,78 ,80 ,81 ,84 ,85 ,85 ,88 ,89 ,91 ,94 ,94 ,98 ,98 ,98 ,98)
> x=fdt(amostra)
> x
Class limits f rf rf(%) cf cf(%)
[33,42) 8 0.15 14.55 8 14.55
[42,52) 5 0.09 9.09 13 23.64
[52,61) 10 0.18 18.18 23 41.82
[61,71) 9 0.16 16.36 32 58.18
[71,80) 10 0.18 18.18 42 76.36
[80,90) 6 0.11 10.91 48 87.27
[90,99) 7 0.13 12.73 55 100.00
Questão 5
> Amostra = c(6 ,5 ,2 ,6 ,4 ,3 ,6 ,2 ,6 ,5 ,1 ,6 ,3 ,3 ,5 ,1 ,3 ,6 ,3 ,4 ,5 ,4 ,3 ,1 ,3,5 ,4 ,4 ,2 ,6 ,2 ,2 ,5 ,2 ,5 ,1 ,3 ,6 ,5 ,1 ,5 ,6 ,2 ,4 ,6 ,1 ,5 ,2 ,4 ,3)
> x=fdt(Amostra)
> x
Class limits f rf rf(%) cf cf(%)
[0.99,1.7) 6 0.12 12 6 12
[1.7,2.4) 8 0.16 16 14 28
[2.4,3.2) 9 0.18 18 23 46
[3.2,3.9) 0 0.00 0 23 46
[3.9,4.6) 7 0.14 14 30 60
[4.6,5.3) 10 0.20 20 40 80
[5.3,6.1) 10 0.20 20 50 100
Questão 6
> Amostra = c(64,64,64,66,66,70,70,73,73,73,73,74,75,76,76,76,78,78,78,78,79,80,80,81,82,82,83,84,84,85,85,85,85,86,86,86,86,86,86,87,87,89,90,90,92,92,93,95,98,101,102,103,103,103,103)
> x=fdt(Amostra)
> x
Class limits f rf rf(%) cf cf(%)
[63.4,69.2) 5 0.09 9.09 5 9.09
[69.2,75) 7 0.13 12.73 12 21.82
[75,80.8) 11 0.20 20.00 23 41.82
[80.8,86.6) 16 0.29 29.09 39 70.91
[86.6,92.4) 7 0.13 12.73 46 83.64
...