jonathancornelissen / highfrequency

The highfrequency package contains an extensive toolkit for the use of highfrequency financial data in R. It contains functionality to manage, clean and match highfrequency trades and quotes data. Furthermore, it enables users to: calculate easily various liquidity measures, estimate and forecast volatility, and investigate microstructure noise and intraday periodicity.
147 stars 63 forks source link

AJjumpTest and BNSjumpTest market open and close time #69

Closed waynelapierre closed 3 years ago

waynelapierre commented 3 years ago

The package manual does not show marketOpen and marketClose arguments for the AJjumpTest and BNSjumpTest functions. How can I change the market open and close times for these two jump test functions?

emilsjoerup commented 3 years ago

You can control this with the data that you input. You can just use the exchangeHoursOnly function.

@kboudt can you close this issue?

waynelapierre commented 3 years ago

Do you mean these two jump tests by default use all the prices/returns within a day?

emilsjoerup commented 3 years ago

They use the data you provide. The data should be cleaned. One of the cleaning steps is to filter out trades outside market hours, so this should never be a problem in these functions.

waynelapierre commented 3 years ago

I understand what you said. It seems inconsistent that some functions like intradayJumpTest provide marketOpen and marketClose arguments while some do not.

emilsjoerup commented 3 years ago

They are typically only there when dealing with spot estimators and the like, and in some cases due to internal usage of functions that require the arguments set to function properly. You are more than welcome to implement any change you wish and make a pull request, then we can discuss the implementation details further.

onnokleen commented 3 years ago

@waynelapierre I agree with Emil. If you have more feature requests, it would be most beneficial for all users if you make a pull request. At the end it's an open source project and we provide support in our spare time.

kboudt commented 3 years ago

Thanks for the various comments @waynelapierre . It's good to have the user feedback.