Precios-clase Hoy 07 Abril

5
DATOS AGRUPADOS >Precios=c(200,158,160,137,188,190,100,178,174,127,150,174,153,199 ,150,148,187,151,103,130,152,188,128,168,175) > Rango=max(Precios)-min(Precios) > Rango [1] 100 > m=round(1+3.3*log10(25)) > m [1] 6 > c=Rango/m > c [1] 16.66667 > > c=17 se aproxima > RNuevo=c*m > RNuevo [1] 102 > RNuevo-Rango [1] 2 > Inicio=min(Precios)-1 > Final=max(Precios)+1 > cbind(Inicio,Final) Inicio Final [1,] 99 201 > Intervalos=cut(Precios,breaks=c(99,116,150,167,184,201)

description

Trabajo en clase

Transcript of Precios-clase Hoy 07 Abril

DATOS AGRUPADOS>Precios=c(200,158,160,137,188,190,100,178,174,127,150,174,153,199,150,148,187,151,103,130,152,188,128,168,175)> Rango=max(Precios)-min(Precios)> Rango[1] 100> m=round(1+3.3*log10(25))> m[1] 6> c=Rango/m> c[1] 16.66667> > c=17 se aproxima> RNuevo=c*m> RNuevo[1] 102> RNuevo-Rango[1] 2> Inicio=min(Precios)-1> Final=max(Precios)+1> cbind(Inicio,Final) Inicio Final[1,] 99 201> Intervalos=cut(Precios,breaks=c(99,116,150,167,184,201)+ )> Intervalos [1] (184,201] (150,167] (150,167] (116,150] (184,201] (184,201] (99,116] (167,184] (167,184] (116,150] (116,150] (167,184] (150,167] (184,201] (116,150] (116,150][17] (184,201] (150,167] (99,116] (116,150] (150,167] (184,201] (116,150] (167,184] (167,184]Levels: (99,116] (116,150] (150,167] (167,184] (184,201]> f=table(Intervalos)> fIntervalos (99,116] (116,150] (150,167] (167,184] (184,201] 2 7 5 5 6 > n=sum(f)> n[1] 25> h=(f/n)> hIntervalos (99,116] (116,150] (150,167] (167,184] (184,201] 0.08 0.28 0.20 0.20 0.24 > F=cumsum(F)> H=cumsum(h)> cbind(f,h,F,H) f h F H(99,116] 2 0.08 0 0.08(116,150] 7 0.28 0 0.36(150,167] 5 0.20 0 0.56(167,184] 5 0.20 0 0.76(184,201] 6 0.24 0 1.00> LimSup=c(116,133,150,167,184,201)> LimInf=c(99,116,133,150,167,184)> X=(LimSup+LimInf)/2> X[1] 107.5 124.5 141.5 158.5 175.5 192.5> f.X=f*X>cbind(f,X,f.X,h,F,H)>Media=Sum(f.X)/n>Media>Sum(f.X)>n/2>Fa=9Fo=5C=17Li=150>Me=Li+((n/2-Fa)/Fo)*C>Me>fo=6fa=5fs=0>delta1=fo-fa>delta2=fo-fsLi=184>Moda=Li+((delta1delta2))*C>Mo>cbind(Media,Me,Mo)>n/4>Li=133Fa=5Fo=4C=17>Q1=Li+((n/4-Fa/Fo)*C>Q1>3*n/4>Li=167Fa=14 fo=5C=17>Q3=Li+((3*n/4=Fa)/fo)*C>Q3>D=abs(X-Media)*f>cbind(f,X,D)>Dm=sum(D)/n>Dm>D2=(X-Media)sombrerito 2*f>cbind(f,X,D2)>Varianza=sum(D2)/n>Varianza>Ds=sqrt(Varianza)>Ds>Cv=Ds7Media>Cv