SOS: Option chain and implied volatility (Bloomberg)

  • Follow


1. How to get option chain? 
In excel : 
A1: SPY US Equity
 =BDS(A1,"OPT_CHAIN","cols=1;rows=1720")
gives me all the options on SPY as the following:

SPY US 06/18/11 C20 Equity
SPY US 06/18/11 C25 Equity
SPY US 06/18/11 C30 Equity
SPY US 06/18/11 C35 Equity
SPY US 06/18/11 C40 Equity
SPY US 06/18/11 C45 Equity
SPY US 06/18/11 C50 Equity
....

How can I do that in Matlab with Bloomberg (Datafeed)?

2. How can I get the 30 day implied vol (for ATM options) in Matlab with Bloomberg (Datafeed)?


Thanks in advance !!
0
Reply Qiusi 6/14/2011 10:00:05 PM

On Jun 14, 6:00=A0pm, "Qiusi " <qzh...@3twelvecapital.com> wrote:
> 1. How to get option chain?
> In excel :
> A1: SPY US Equity
> =A0=3DBDS(A1,"OPT_CHAIN","cols=3D1;rows=3D1720")
> gives me all the options on SPY as the following:
>
> SPY US 06/18/11 C20 Equity
> SPY US 06/18/11 C25 Equity
> SPY US 06/18/11 C30 Equity
> SPY US 06/18/11 C35 Equity
> SPY US 06/18/11 C40 Equity
> SPY US 06/18/11 C45 Equity
> SPY US 06/18/11 C50 Equity
> ...
>
> How can I do that in Matlab with Bloomberg (Datafeed)?
>
> 2. How can I get the 30 day implied vol (for ATM options) in Matlab with =
Bloomberg (Datafeed)?
>
> Thanks in advance !!

Warning:
This is from memory since I dont have access to bloomberg to test.


first open a channel to bloomberg:

c =3D bloomberg(); % depending on your version of matlab you may need to
use blp()

1.

>> oc =3D fetch(c, 'SPY US Equity', 'GetData','OPT_CHAIN');

2.

>> vol =3D fetch(c, oc.OPT_CHAIN, ,'GetData',{'OPT_STRIKE_PX','OPT_PUT_CALL=
',...
               'OPT_EXPIRE_DT','OPT_IMPLIED_VOLATILITY_MID'});

/reza
0
Reply mjahanbin (124) 6/15/2011 12:18:31 AM


Thanks, it helps a lot ! 

Another thing is that is fetch a current or both current and historial? 

So if I add a date in the end of the fetch option, could it work? And in what format?

'06/13/2011' or ...?
0
Reply Qiusi 6/15/2011 3:18:07 PM

On Jun 15, 11:18=A0am, "Qiusi " <qzh...@3twelvecapital.com> wrote:
> Thanks, it helps a lot !
>
> Another thing is that is fetch a current or both current and historial?
>
> So if I add a date in the end of the fetch option, could it work? And in =
what format?
>
> '06/13/2011' or ...?

fetch() arguments are too rich to explain here. Goto matlab gui help
by typing helpwin

in the gui help search for bloomberg, in the "See Also" section click
on fetch.bloomberg

You can also use a GUI by typing dftool in matlab to Historical, live
tick data.

/reza

0
Reply mjahanbin (124) 6/15/2011 11:31:59 PM

Ok, thanks. I get the format of the date.

But now I have an emergency, is there possible to get historical data (no matter using fetch or history) and return a structure (instead of cells). 

Our company is running tests to choose the best fit software, plz reply asap, thanks a lot!
0
Reply em5357 (6) 6/16/2011 4:37:04 PM


"Zoe " <em5357@hotmail.com> wrote in message 
news:itdbfg$rp$1@newscl01ah.mathworks.com...
> Ok, thanks. I get the format of the date.
>
> But now I have an emergency, is there possible to get historical data (no 
> matter using fetch or history) and return a structure (instead of cells).
> Our company is running tests to choose the best fit software, plz reply 
> asap, thanks a lot!

I don't know how many experts there are on the Bloomberg interface in 
Datafeed Toolbox on CSSM. You should send a description of what you're 
trying to do to Technical Support; they should be able to describe what to 
do to accomplish your goal.

-- 
Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on 
http://www.mathworks.com 

0
Reply slord (13282) 6/16/2011 8:25:37 PM

I attempted this, but am told that "OPT_CHAIN" is an invalid field requested. Am I missing something? (I do have the datafeed toolbox).

Thanks,
Jeremy
0
Reply firetiger77 (2) 8/17/2012 11:27:13 PM

"Jeremy Long" wrote in message <k0mk0h$98a$1@newscl01ah.mathworks.com>...
> I attempted this, but am told that "OPT_CHAIN" is an invalid field requested. Am I missing something? (I do have the datafeed toolbox).
> 
> Thanks,
> Jeremy

chain = getdata(c,'SPX Index','OPT_CHAIN')
0
Reply Zoe 8/18/2012 7:25:08 PM

"Jeremy Long" wrote in message <k0mk0h$98a$1@newscl01ah.mathworks.com>...
> I attempted this, but am told that "OPT_CHAIN" is an invalid field requested. Am I missing something? (I do have the datafeed toolbox).
> 
> Thanks,
> Jeremy


>> chain = getdata(c,'SPX Index','OPT_CHAIN')

chain = 

    OPT_CHAIN: {{1814x1 cell}}
0
Reply Zoe 8/18/2012 7:27:07 PM

"Zoe Zhang" <qzhang@3twelvecapital.com> wrote in message <k0oqab$lbt$1@newscl01ah.mathworks.com>...
> "Jeremy Long" wrote in message <k0mk0h$98a$1@newscl01ah.mathworks.com>...
> > I attempted this, but am told that "OPT_CHAIN" is an invalid field requested. Am I missing something? (I do have the datafeed toolbox).
> > 
> > Thanks,
> > Jeremy
> 
> 
> >> chain = getdata(c,'SPX Index','OPT_CHAIN')
> 
> chain = 
> 
>     OPT_CHAIN: {{1814x1 cell}}


Thank you for the help. Is there a way to get the option chains from yahoo finance? 
Thanks,
Jeremy
0
Reply firetiger77 (2) 8/22/2012 9:38:07 PM

"Jeremy Long" wrote in message <k13jfv$35s$1@newscl01ah.mathworks.com>...
> "Zoe Zhang" <qzhang@3twelvecapital.com> wrote in message <k0oqab$lbt$1@newscl01ah.mathworks.com>...
> > "Jeremy Long" wrote in message <k0mk0h$98a$1@newscl01ah.mathworks.com>...
> > > I attempted this, but am told that "OPT_CHAIN" is an invalid field requested. Am I missing something? (I do have the datafeed toolbox).
> > > 
> > > Thanks,
> > > Jeremy
> > 
> > 
> > >> chain = getdata(c,'SPX Index','OPT_CHAIN')
> > 
> > chain = 
> > 
> >     OPT_CHAIN: {{1814x1 cell}}
> 
> 
> Thank you for the help. Is there a way to get the option chains from yahoo finance? 
> Thanks,
> Jeremy

That I am not sure. I just use BBG.
0
Reply Zoe 8/22/2012 9:51:07 PM

10 Replies
35 Views

(page loaded in 0.148 seconds)


Reply: