Thank you, Dudetooth and Ron!
I manually downloaded cme.s.pa2 from CME site and renamed the nyb.20131210.s.pa2 to nyb.s.pa2. Now it seems to work OK!
I can edit VBA only following step by step instructions.
After reading what vp62 did, I checked the CME website and realized that there is a file named cme.s.pa2.zip that is the current file without the date in it. There is also an unzipped version too. cme.s.pa2
Does anyone happen to know what CME uses net delta for? This goes back to Kevin's observation that the delta seems too high for currencies when calculated by PC-SPAN. The delta in the risk arrays is referred to composite delta by CME. Depending on the market, the composite delta is multiplied by a scaling factor to create the net delta. I'm wondering if this net delta can be ignored when we are looking at finding the delta of a single position or simple spread.
Here's the latest spreadsheet with a few updates (just in time for the Holidays):
Added Aus Dollar, Brit Pound, Can Dollar, Soybean Meal, Soybeal Oil, Copper, T-Bills, T-Notes, Eurodollars (see Setup tab in spreadsheet for all commodities supported).
Modified the selection process so that you can now calculate for multiple options. Click + drag or ctrl + click to select your option(s). Run multiple calculations without running the entire portfolio or running each one at a time. The process will seem a little backwards at first: now you select the option(s) first and then click the button. 'Add to Portfolio' and Delete Selection' use the same selection method allowing you to use that feature on multiple options. Selection for the Spread Risk is done the old way (click button first and then select option).
No longer displaying the SPAN IM, SPAN MM and Total MM, just showing Total IM.
Now displaying the 'composite delta' for the individual option. As noted earlier in conversations, EC, JY, S, W, and C have their delta multiplied by a certain factor when run through PC-SPAN. From what I have been able to gather this is called 'net delta' by CME and is used when calculating for the offsetting of positions within a portfolio. 'Net delta' shouldn't really be a factor when analyzing individual options.
Added ROI to the calculated fields with the ability to adjust the multiple of IM you want held for that position.
Tried to streamline code to run a little faster by stopping Excel from making unnecessary calculations while running the code and grabbing more from the risk arrays rather than making calculations (a lot of what we need is right in the arrays).
Tried to trap most of the errors so that they cause the code to simply exit, except when running Portfolio Risk (errors will skip current line and continue). So if you calculate for an option and no data is populated it is likely that the option was not found (wrong month or strike).
Added some basic portfolio tools to track trades and delete old calculations.
Old pa2 files and their zips are deleted by default so you don't get a build-up in your folder.
I'm just supplying the 97/2003 version .xls to make things simpler.
I've run a couple of tests using options for each commodity that can be calculated in the spreadsheet at this time and I am pretty sure I have most of the bugs worked out. I've noticed that Total IM may be off from what is reported in PC-SPAN, but with the discrepancies I saw it was less than $1. As usual, please let me know if you find any issues and I will try to get them fixed.
How is the spreadsheet you developed different from the pc-span software created by the exchange? Is the spreadsheet able to calculate able to compute span margins without the pc-span software installed? Thanks.
Like Ron said, you don't need the PC-SPAN software installed, BUT you DO need the PC-Span risk files. You'll notice in the spreadsheet a data field in the upper left corner of the spreadsheet next to the "Download Risk Arrays" button. You enter the most recent trading date (at least after 6pm Chicago time) and click on "Download Risk Arrays" button. This downloads the PC-Span risk files. Once you have that you should be able to use the spreadsheet to figure SPAN margins.
The spreadsheet also differs from PC-SPAN in that it is limited in what it can calculate. It cannot compute margin for complex spreads and for entire portfolios. The setup tab in the spreadsheet takes you step by step through what the spreadsheet can do.
I made a copy of Margin without PC SPAN for just ES weeklies and changed CalcRisk to look for 3 digits in con1 and added the product codes for EW and each weekly contract like EW1. I added a space after the 2 digit symbols and that worked OK for them. So ES and CL are working.
But it is not working for EW or EW1. It just comes back with the ES option not the EW or EW1 option.