View source: R/car_nonparametric_tests.R
car_rank_test | R Documentation |
A nonparametric test proposed by Cowan 1992 as an extension of the rank test proposed by Corrado 1989.
car_rank_test(list_of_returns, car_start, car_end, percentage = 90)
list_of_returns |
a list of objects of S3 class |
car_start |
an object of |
car_end |
an object of |
percentage |
a lowest allowed percentage of non-missing observation for each day to be incorporated into CAR. The default value is 90 percent.
|
This function performs a test proposed by Cowan 1992 to investigate the
significance of the CAR for a given period. In order to get ranks of
corresponding abnormal returns, the procedure uses regular R function
rank
with parameter ties.method = "average"
and
na.last = "keep"
. For this test the estimation period and the event
period must not overlap, otherwise an error will be thrown. The test
statistic is assumed to have a normal distribution (as an approximation). The
test is well-specified for the case, when cross-sectional abnormal returns
are not symmetric. The test is stable to variance increase during given
period. This test ignores the dependence of abnormal returns' ranks of
different days (i.e., a serial dependence). The critical values are standard
normal. The significance levels of \alpha
are 0.1, 0.05, and 0.01
(marked respectively by *, **, and ***).
Corrado C.J. A Nonparametric Test for Abnormal Security-Price Performance in Event Studies. Journal of Financial Economics 23:385-395, 1989.
Cowan A.R. Nonparametric Event Study Tests. Review of Quantitative Finance and Accounting, 2:343-358, 1992.
car_nonparametric_tests
.
## Not run:
library("magrittr")
rates_indx <- get_prices_from_tickers("^GSPC",
start = as.Date("2019-04-01"),
end = as.Date("2020-04-01"),
quote = "Close",
retclass = "zoo") %>%
get_rates_from_prices(quote = "Close",
multi_day = TRUE,
compounding = "continuous")
tickers <- c("AMZN", "ZM", "UBER", "NFLX", "SHOP", "FB", "UPWK")
get_prices_from_tickers(tickers,
start = as.Date("2019-04-01"),
end = as.Date("2020-04-01"),
quote = "Close",
retclass = "zoo") %>%
get_rates_from_prices(quote = "Close",
multi_day = TRUE,
compounding = "continuous") %>%
apply_market_model(regressor = rates_indx,
same_regressor_for_all = TRUE,
market_model = "sim",
estimation_method = "ols",
estimation_start = as.Date("2019-04-01"),
estimation_end = as.Date("2020-03-13")) %>%
car_rank_test(car_start = as.Date("2020-03-16"),
car_end = as.Date("2020-03-20"))
## End(Not run)
## The result of the code above is equivalent to:
data(securities_returns)
car_rank_test(
list_of_returns = securities_returns,
car_start = as.Date("2020-03-16"),
car_end = as.Date("2020-03-20")
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.