turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- Analytics
- /
- Stat Procs
- /
- Help with 3 tests

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-07-2015 08:18 AM

Hi all,

My data currently look like this:

Time To Maturity Volatility

1 0.65

2 0.21

3 0.33

I am looking to run the following three tests on my data and want to make sure I am doing so correctly.

1.Jonckheere-Terpstra test

To examine if the volatility increases as a contract approaches maturity

2.Newy West Heteroskedasticity Consistent Covariance Procedure

To regress the daily future realised volatility on a constant and the number of days until the contract matures.

3.GARCH (1, 1) model

I want to make sure I am coding this correctly in order to ascertain that the results are correct.

Any assistance will be greatly appreciated.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-07-2015 08:40 AM

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-07-2015 10:00 AM

The JT test is dependent on discordant observations for ordinal categories, so it will definitely need more observations than the 3 mentioned (I assume that is a sample, and not the whole dataset). PROC FREQ offers the JT test, including an exact test.

Newey-West and GARCH models are implemented in the SAS/ETS package. The good folks in the Forecasting and Econometrics forum will have a much better chance of being to answer your questions about which PROCs to implement to meet your goals

Steve Denham.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-07-2015 10:05 AM

Hi Steve,

Thanks so much for your response. Yes- that is just a sample.. Do you know the exact syntax for the proc freq test?

Regards,

Terri

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-07-2015 01:16 PM

Hi Terri,

To make a JT test work, you'll probably need to code volatility into some sort of ordinal variable. Deciles would make sense. Also, I am assuming time to maturity doesn't take on too many values, or it too would have to be coded. Once that is done, you could then run:

proc freq data=yourcodeddata;

tables time*volatility_decile/jt;

run;

If there are not too many levels of the two variables, you could get an exact test with:

proc freq data=yourcodeddata;

tables time*volatility;

exact jt; /* You could add the mc option after a slash here to get a Monte Carlo simulation, if execution time seems inordinate */

run;

Steve Denham

Message was edited by: Steve Denham

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-08-2015 04:02 AM

Thanks Steve - that works perfectly.

For the second test i.e. the Newy West Heteroskedasticity Consistent Covariance Procedure where by I need to regress the daily future realised volatility on a constant and the number of days until the contract matures do you know how I would do this?

Kind regards,

Terri

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

07-08-2015 11:38 AM

Definitely outside my usual work, but a search of the documentation points to PROC AUTOREG or PROC MODEL in SAS/ETS. At this point, your best bet would be to ask the Forecasting and Econometrics forum for help.

Steve Denham