Description Usage Arguments Details Value References
Estimates the model of Huang & Stoll (1997)
1 | estimate_hs(price_diff, price, indicator, indicator_lag, midquote)
|
price_diff |
a numeric vector containing the series of first price differences. |
price |
a numeric vector containing the price series. |
indicator |
an integer vector containing the trade direction with a buy as 1 and a sell as -1. |
indicator_lag |
an integer vector containing the first lag of the indicator series. |
midquote |
a numeric vector with the midquote price series. |
The function estimates for given data the trade indicator model of
Huang & Stoll (1997).
For estimation an OLS approach is used similar to the one desribed in the paper of the two
authors. For application the lm
-function is used together with
NeweyWest
for NeweyWest standard errors. For details
it is referred to the NeweyWest
-function.
A data.frame with the following values:
the number of observation used in estimation.
the effective half-spread.
the standard deviation of the effective half-spread.
the t-value of the effective half-spread.
the p-value of the effective half-spread.
the part of the spread due to adverse selection and inventory.
the standard deviation of the adverse selection and inventory
spread component.
the t-value of the adverse selection and inventory
spread component.
the p-value of the adverse selection and inventory
spread component.
the coefficient of determination.
the adjusted coefficient of determination.
the value of the F-statistic.
the p-value of the F-statistic.
the effective spread estimated from the model using the formula 2(θ+φ).
the standard deviation of the effective spread, calculated via the delta method.
the empirical effective spread, calculated directly from the data by the arithmetic mean of the series q_t(p_t-m_t), where q_t is the trade direction, p_t the transaction price, and m_t the price midquote series.
the standard deviation of the empirical effective spread calculated as the standard deviation of the series q_t(p_t-m_t).
the standard error of the estimated empirical effective spread using the formula SE=STD/√ n.
the median of the empirical effective spread calculated as the median of the series q_t(p_t-m_t).
Huang & Stoll (1997), "The Component of the Bif-Ask Spread: A General Approach," The Review of Financial Studies, Vol. 10, Issue 4., pp. 995-1034.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.