SmartQuant Discussion

Automated Quantitative Strategy Development, SmartQuant Product Discussion and Technical Support Forums
It is currently Wed Sep 26, 2018 4:23 am

All times are UTC + 3 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Fri Jul 04, 2008 2:30 pm 
Offline

Joined: Wed Sep 26, 2007 10:03 pm
Posts: 100
Hi

I am paper trading a portfolio of futures with IB. But before I want to execute a trade, I would like to know the margin requirement (in order to keep my my total margin-to-equity ratio below a certain security level).

How can I get in OQ the margin requirement for a specific futures contract from IB before I make the trade?

Thanks for your help!

Boris


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 07, 2008 6:39 am 
Offline

Joined: Thu Apr 03, 2008 6:28 am
Posts: 49
There is a Margin property for both Instrument and Position. The Instrument.Margin is, according to the API documentation, the instrument initial margin. I would think that you'd need to be relying on IB for the Instrument data in order for that value to be set properly, though. I don't know how to manually request it from IB.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 07, 2008 12:17 pm 
Offline
Site Admin

Joined: Thu Jul 17, 2003 10:39 am
Posts: 1478
Hi Boris,

I think you can obtain some information from IB in BrokerInfo window(View->BrokerInfo) - thats all that IB sends from TWS to OQ.

Regards,
Alex

_________________
SmartQuant Development Team


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 07, 2008 1:23 pm 
Offline

Joined: Wed Sep 26, 2007 10:03 pm
Posts: 100
Thanks for your answers.

I already checked BrokerInfo, but there I can only see the total margin of my account, and this information is based on current positions I am invested in.

Conclusion is: Within the OQ framework, I cannot check the margin of a specific instrument before I make the trade. Is that right?

Of course I can check the margin of the account after I have done the trade, but this is unsatisfactory. In IBs TWS I can check the margin before I make the trade. Unfortunately it seems this is not possible within OQ. I am wondering how people are trading futures with OQ without this possibility?

Regards,
Boris


Top
 Profile  
 
 Post subject: Re:
PostPosted: Wed Nov 30, 2011 7:31 pm 
Offline

Joined: Fri Sep 09, 2011 12:44 pm
Posts: 34
Wacka wrote:
There is a Margin property for both Instrument and Position. The Instrument.Margin is, according to the API documentation, the instrument initial margin. I would think that you'd need to be relying on IB for the Instrument data in order for that value to be set properly, though. I don't know how to manually request it from IB.


I still don't get what the Margin property significants - I know it is an initial margin, but - is it in dollars, in percents, is it a multiplier? Lets imagine I have a stock instrument, like AAPL, price $400 per share. Let's assume the initial margin is 50% for this stock (standard across most brokers).
So if I buy 100 shares 400 each, margin used should be 20k. What I setup in instrument margin? 0.5 nor 50 seems to do the job?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC + 3 hours


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group