SAS enterprise guide
-
Upload
andrew-reeves -
Category
Documents
-
view
73 -
download
5
description
Transcript of SAS enterprise guide
Robert Petzer 448889 (Finance)
Nathanael Seeber 518599 (Finance)
Tracy Favish 481059 (Finance)
Andrew Reeves 304092 (Finance)
Clayton Redford 389261 (Finance)
Bradley Tighy 376372 (Finance)
Bradley Campleman 435792 (Finance)
University of the Witwatersrand
Stats Assignment 1
[Type the document subtitle]
Question 1
The data used is randomly selected. We made use of both gold and platinum share prices from various companies. The values are completely random and no real world sample was used. Therefore there is variability in the data. If, for example, we used the actual historical data on these companies, there would be less variability. This variability is also affected by the method used to collect the data as well as the sample used.
A completely random sample results in large variability. In the real world, gold and platimun share prices are affected by investor sentiment, political upheaval, public information and various macroeconomic factors such as the interest rate, inflation etc.
Question 2
Summary Statistics Results
The MEANS Procedure
Analysis Variable : BeforeMarikana Mean Std Dev Minimum MaximumMode NLower Quartile MedianUpper Quartile
149.482500029.899433
398.660000
0206.980000
0 .12 135.9950000
151.0100000 160.1300000
Generated by the SAS System ('Local', W32_7PRO) on 21 February 2013 at 9:57:23 AM
Inter-quartile range = Q3-Q1 = 160.13-135.99 = 24.14
Question 3a)
Summary Statistics Histograms
The UNIVARIATE Procedure
*Note: The interval width changed from 20 to 10 units.
b)
Summary Statistics Box and Whisker Plots
c) The mean, median, mode and inter-quartile range will remain the same as the data does not change. However drastic changes occur in the histogram’s distribution. The second histogram showed a slight skewing of the data to the left. The increased number of intervals makes the graph more detailed and easier to interpret.
No changes occured in the box-and-whisker plot. The box itself represents the inter-quartile range.
Question 4
A hypothesis could be formulated to test the mean share price before the Marikana tragedy. Based on the above data, we will test whether the mean share price is significantly different from R120. We will test at a significance level of 5%.
H0: µ =120H1: µ =120
Question 5
a) H0: µ =120 H1: µ =120
The mean price of shares before the Marikana tragedy is R120. (Null Hypothesis)The mean price of shares before the Marikana tragedy is not R120. (Alternative Hypothesis)Two-tail test.
t Test The TTEST Procedure
Variable: BeforeMarikana
N Mean Std DevStd ErrMinimumMaximum
12149.
529.899
48.6312 98.6600 207.0Mean95% CL Mean Std Dev95% CL Std Dev
149.5 130.5 168.529.899
421.180
650.765
6DFt Value Pr > |t|
11 3.420.005
8
The T-stat exceeds the T-critical value (3.42 > 2.201) and the P-value is less than the significance level (0.0058 <0.05) Therefore we reject the null hypothesis at a 5% level of significance and as such the mean share price before the Marikana tragedy is significantly different from R120.
b)
t Test
The TTEST Procedure
Variable: BeforeMarikana
N Mean Std DevStd ErrMinimumMaximum
12149.
529.899
48.6312 98.6600 207.0Mean99% CL Mean Std Dev99% CL Std Dev
149.5 122.7 176.329.899
419.170
961.461
6DFt Value Pr > |t|
11 3.420.005
8
No, it does not make a difference. Since the P-value of 0.0058 is still less than 0.01, we reject H0 at 1% level of significance.
c)
The P-value for the 2 sided test = 0.0058
Therefore, the P-value for the one-sided test is 0.0029.
This is less than both significance levels of 0.05 and 0.01.
d)
Our conclusion would change from reject to do not reject for the two-sided test at a level of significance of 0.58%.
Question 6
t Test The TTEST Procedure
Variable: BeforeMarikana
CommodityN Mean Std Dev Std ErrMinimumMaximum
G 6 148.432.927
513.442
6 108.5 207.0
P 6 150.629.658
412.108
0 98.6600 187.4
Diff (1-2) -
2.201731.335
618.091
6 Commodity Method Mean 90% CL Mean Std Dev 90% CL Std Dev
G 148.4 121.3 175.5 32.9275 22.1289 68.7940P 150.6 126.2 175.0 29.6584 19.9319 61.9640Diff (1-2) Pooled -2.2017 -34.9920 30.5887 31.3356 23.1595 49.9199Diff (1-2) Satterthwaite -2.2017 -35.0282 30.6248
Method Variances DFt Value Pr > |t|
Pooled Equal 10 -0.120.905
6
SatterthwaiteUnequal9.892
6 -0.120.905
6Equality of Variances
Method Num DFDen DFF Value Pr > F
Folded F 5 5 1.230.824
1
a)
H0: µ1 = µ2
H1: µ1 = µ2
The null hypothesis states that the mean share price of gold is equal to the mean share price of platinum.
The alternative hypothesis states that the mean share price of gold is not equal to the mean share price of platinum.
The F-test for the equality of variances gave us a p-value of 0.8241 which is greater than 0.1. Thus, at a 10% level of significance we fail to reject H0: that the variances are the same.
Since we failed to reject the null hypothesis, we used the pooled test to test the hypotheses again. This gives us a P-value of 0.9056. Since this is still greater than the 10% level of significance we failed to reject the null hypothesis.
This shows that the mean of group 1 is equal to the mean of group 2.
b)
The 90% confidence interval using the pooled method is (-34.9920;30.5887)
c)
Testing at a 1% level of significance makes no difference to our findings as the p-value of 0.9056 is greater than 0.01.
d)
It would change at level of significance equal to 90.56%
e)
t Test The TTEST Procedure
Variable: BeforeMarikana
Commodity N Mean Std Dev Std ErrMinimumMaximum
G 6 148.432.927
513.442
6 108.5 207.0
P 6 150.629.658
412.108
0 98.6600 187.4
Diff (1-2) -
2.201731.335
618.091
6
Commodity Method Mean 99% CL Mean Std Dev 99% CL Std Dev
G 148.4 94.1793 202.6 32.9275 17.9904 114.7
P 150.6 101.8 199.4 29.6584 16.2043 103.4
Diff (1-2) Pooled -2.2017 -59.5389 55.1356 31.3356 19.7442 67.4882
Diff (1-2) Satterthwaite -2.2017 -59.6786 55.2753 Method Variances DFt Value Pr > |t|
Pooled Equal 10 -0.120.905
6
SatterthwaiteUnequal9.892
6 -0.120.905
6Equality of Variances
Method Num DFDen DFF Value Pr > F
Folded F 5 5 1.230.824
1
The 99% confidence level is (-59.5389;55.1356)
Question 7
a)
t Test The TTEST Procedure
Difference: BeforeMarikana - AfterMarikana
N Mean Std DevStd ErrMinimumMaximum
1219.826
717.086
94.9326 -13.5700 37.6700Mean 90% CL Mean Std Dev90% CL Std Dev
19.826710.968
328.685
017.086
912.776
226.495
6DFt Value Pr > |t|
11 4.020.002
0
H0: µD = 0 i.e µ1 - µ2 = 0H1: µD = 0
The p-value of 0.002 is less than the 3 significance levels of 10%, 5% and 1%. Thus at all levels of significance we reject the null hypothesis and find that the means for each sample are statistically different i.e. the mean share price changes post-Marikana.
b)
There is no difference in our conclusion at the different significance levels as 0.002 is less than 0.1, 0.05 and 0.01. We reject the null hypothesis at all levels of significance.
c)
Our conclusion would change at a significance level of 0.2% - at this level we would fail to reject the null hypothesis.