Hello,
I am trying to run a z-test on the mean of a variable of a portfolio (top 10 percent of an index) compared to the mean of a benchmark (the index).
The portfolio is created using a binary variable with a 1 if it is a part of the portfolio and otherwise 0, this column is being called PB10.
Using the command; ztest gendivY, by(PC10) - the following output is presented
ztest gendivY, by(PB10)
Two-sample z test
------------------------------------------------------------------------------
Group | Obs Mean Std. Err. Std. Dev. [95% Conf. Interval]
---------+--------------------------------------------------------------------
0 | 536,150 22.02248 .0013657 1 22.0198 22.02516
1 | 60,132 27.14717 .004078 1 27.13918 27.15516
---------+--------------------------------------------------------------------
diff | -5.12469 .0043006 -5.133119 -5.116261
------------------------------------------------------------------------------
diff = mean(0) - mean(1) z = -1.2e+03
Ho: diff = 0
Ha: diff < 0 Ha: diff != 0 Ha: diff > 0
Pr(Z < z) = 0.0000 Pr(|Z| > |z|) = 0.0000 Pr(Z > z) = 1.0000
In this test the portfolio(1) is compared to the rest (the 0), but not compared to the benchmark which would be PB10(1+0). Is there any way in which I can run a z-test testing the portfolio against the whole benchmark?
Thank you very much in advance!
Related Posts with Z-test for a portfolio and a benchmark
table1_mc can now also report the value of the test statisticThe latest version of table1_mc is now available to download on SSC. Code: . search table1_mc The m…
hbar and detection limitsHi all, Can someone assist with plotting an hbar for detection limits of different concentrations (…
Query in Breusch-Pagan test for panel dataHello everyone, I am new to this forum. I would like to test my panel data model for Heterskedastici…
Storing regression outputs / panel data / issue with system limits / percentage of positive constantsDear Stata users, I am working with panel data. I am running regressions for each id with: bysort …
summarize a variable in panel dataHello, I want to make a descriptive analysis on variables of my panel data. I have attached the dat…
Subscribe to:
Post Comments (Atom)
0 Response to Z-test for a portfolio and a benchmark
Post a Comment