Skip to main content

Module # 3 assignment

 >first<- c(10,2,3,2,4,2,5)

> second<- c(20,12,13,12,14,12,15)

1.CENTRAL TENDENCY
> #Central Tendency for first
> mean(first)
[1] 4

> median(first)
[1] 3

> #Central Tendency for second
> mean(second)
[1] 14

> median(second)
[1] 13


2. VARIATION
> #Variation for first
> sd(first)
[1] 2.886751

> range(first)
[1]  2 10

> quantile(first)
  0%  25%  50%  75% 100%
 2.0  2.0  3.0  4.5 10.0

> var(first)
[1] 8.333333

> #Variation for second
> sd(second)
[1] 2.886751

> range(second)
[1] 12 20

> quantile(second)
  0%  25%  50%  75% 100%
12.0 12.0 13.0 14.5 20.0

> var(second)
[1] 8.333333

 3. 

    Let's start with the differences, which are mostly centered around the Central tendency area of the things that were tested. The mean, median, and mode are all different by 10 each, and while the mode is not there since I couldn't figure out how to calculate it, it is also up by 10. The mode for first and second is 2 12, respectively. The other difference is the interquartile range, and the same holds true for it being raised by 10.



    Now for the similarity, all or the variance except IQR are the same for the same reason that the central tendency is different. Due to the number sets just being the same but adding 10, it makes the variance not change, just the numbers we are dealing with difference, and the spread is still the same. The best example would be the range. While it looks different, basic subtraction would tell you they are the same, which is what is happening in the case of first and second with different numbers but the same result.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Comments