I made a code mod for this purpose to make things a bit more straightforward for people in my situation.
I have standard user account, but I have multiple sub-accounts (long story here), but I basically just treat them as different accounts in one user interface. I don't distribute orders or anything like that, I just pick which account my orders route through, and then can look at each portfolio individually. My code mod polls IB when it attempts to connect, retrieves a list of available accounts, and pops up a comboBox dialog where you can pick an account (this step is skipped if only one account is available). This is the only account this instance of JBT will use. This appears to work great for for forward testing. For trading I added a line in placeOrder to set this account code in the order. I haven't tested whether this works in trade mode. If anyone wants a patch, let me know! -Judson On Tue, Mar 22, 2011 at 8:14 PM, Da Xu <[email protected]> wrote: > I called IB several times. They told me any subaccount has its own margin. > In fact, when I trade using my master account(selected ALL), I found the > margin would be the minimal margin of all the margins of all the > subaccounts. > > > Da > > On Thu, Mar 17, 2011 at 1:51 PM, alrts <[email protected]>wrote: > >> I don't think it's implemented in JBT 8.04, or I am missing >> something ? >> >> For the time being, I just want to be able to trade one account of a >> multi-account. >> >> Yes, you are right, there is more to it. But you do not distribute the >> profit. You trade a different number of contracts for each account by >> issueing just one order. For our purposes, there would be 3 steps: >> >> (1) replaceFA(1, xml): >> Define a subgroup of accounts of your multi-account as an xml string >> >> (2) replaceFA(2, xml) >> Define a security and it's allocation (i.e. how many contracts for >> account1, how many contracts for account2, ...) as an xml string, a so >> called profile, and give it a profileName (contained within the xml >> string). In our case this would be a profile with only one security in >> it. The accounts referenced must be a subset of the subgroup defined >> in step 1. >> >> (3) placeOrder(id, contract, order) >> order.m_faProfile contains the profileName, and order.m_totalQuantity >> should contain the sum of quantities defined for the different >> accounts within the profile. PS: if order.m_faProfile != "", then >> order.m_account = "", order.m_faGroup = "", order.m_faMethod = "" as >> all information is stored within the profile already. >> >> That's all there is to it. In an FA multi-account, the master account >> is not meant to be traded, and each other subaccount has his own >> margin requirements. In an institutional multi-account, there is no >> master account and margin is shared among all accounts. >> >> -- >> You received this message because you are subscribed to the Google Groups >> "JBookTrader" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/jbooktrader?hl=en. >> >> > -- > You received this message because you are subscribed to the Google Groups > "JBookTrader" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/jbooktrader?hl=en. > -- You received this message because you are subscribed to the Google Groups "JBookTrader" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/jbooktrader?hl=en.
