Portfolio Money Management and Autotrading

Questions about MultiCharts and user contributed studies.
elaskaris
Posts: 17
Joined: 31 Mar 2008

Portfolio Money Management and Autotrading

Postby elaskaris » 05 Jun 2008

Hey,

I am developing a long-term trading strategy to be autotraded on a basket of stocks. The Portfolio Backtester has money management and risk management features that I am wondering how to implement when autotrading through IB.

For instance, the Portfolio Backtester dynamically montiors portolio equity so that it doesn't place another order when it would violate your max exposure setting or exceed your total equity. I am wonder how to do the same when autotrading with IB.

When I apply a strategy to autotrade 10 stocks with a maximum of, say, 15% of total equity per position (meaning max 6 positions at any given time if you expose 100% of your equity). It sounds like I need to have all 10 charts open in different windows with the strategy set to trade only 15% of my capital, praying no more than 6 positions are open at once? Is there a way to dynamically monitor capital and prioritize symbols (like the portfolio backtester) so when capital is low the user prefered stocks are traded preferentially?

Thanks,
Evan

User avatar
Marina Pashkova
Posts: 2758
Joined: 27 Jul 2007

Postby Marina Pashkova » 10 Jun 2008

Hi Evan,

You're the first of our customers to raise this very insteresting issue, which shows that you fully understand the essence of portfolio backtesting and trading and the tasks they solve.

At this point, the dynamic portfolio approach cannot be used to actually trade your strategies. It only works for backtesting. To use this approach in autotrading, the strategy must be calculated on each bar for all symbols in all charts and know how much money has become available after a position has been closed in one chart to enter a position in another chart etc. However, in autotrading, the strategy doesn't get a feedback from other charts and can't treat them as parts of a larger unit with complex dynamic ties.

We know that the next logical step after introducing portfolio backtesting would be to implement portfolio autotrading. However, there's no demand for this feature, so it has a rather low priority. We are planning to implement this feature in future, but only after the issues with higher priority have been solved.

What we can suggest is as follows:

If you purchase MultiCharts Pro for $9900, we will start working on this feature right away. Once developed, portfolio autotrading will be available to other customers as well. In other words, if you decide to invest $9900 in our software, you'll speed up the development of portfolio trading.

Regards.

elaskaris
Posts: 17
Joined: 31 Mar 2008

Postby elaskaris » 10 Jun 2008

Thank you for the reply Marina. I am encouraged to see that you realize the value of incorporating this feature into Multicharts down the line.

If I had the money to expend on software, I would certainly consider the PRO license, as I am sure that the progammer time and support attention required to get this feature working (at my request) would cost as much as the PRO license.

As a temporary, but admittedly less desireable, workaround I have an idea I would like to ask you about. Is it possible to have the strategy "Require order confiramtion" when generating "Buy" signals, and the switch it to "No order confiramtion" after the strategy has exectured the purchase? This would allow me approve purchases, and allow the strategy to execute stop-losses automatically from there on without my approval. The time sensitivity and dynamic nature of the exits is more critical than the entries.

In this way I could dynamaically calculate total portfolio equity and assign fixed percent investment for each trade. I could also act as a "Gatekeeper" to prevent the strategy from attempting to buy when I have already exposed the max capital I wish to. If confronted by too many buy signals at once, I could prioritize and only approve purchases I desire.

Being able to change from "Require Order Confirmation" to "Do Not Require Order Confirmation" dynamically AFTER a Buy order has executed would at least let me fashion a work-around for now. The question is whether or not it can be done? Please let me know.

Thanks again for your attention to user questions/requests.

Evan

User avatar
Marina Pashkova
Posts: 2758
Joined: 27 Jul 2007

Postby Marina Pashkova » 11 Jun 2008

Thank you for the reply Marina. I am encouraged to see that you realize the value of incorporating this feature into Multicharts down the line.

If I had the money to expend on software, I would certainly consider the PRO license, as I am sure that the progammer time and support attention required to get this feature working (at my request) would cost as much as the PRO license.

As a temporary, but admittedly less desireable, workaround I have an idea I would like to ask you about. Is it possible to have the strategy "Require order confiramtion" when generating "Buy" signals, and the switch it to "No order confiramtion" after the strategy has exectured the purchase? This would allow me approve purchases, and allow the strategy to execute stop-losses automatically from there on without my approval. The time sensitivity and dynamic nature of the exits is more critical than the entries.

In this way I could dynamaically calculate total portfolio equity and assign fixed percent investment for each trade. I could also act as a "Gatekeeper" to prevent the strategy from attempting to buy when I have already exposed the max capital I wish to. If confronted by too many buy signals at once, I could prioritize and only approve purchases I desire.

Being able to change from "Require Order Confirmation" to "Do Not Require Order Confirmation" dynamically AFTER a Buy order has executed would at least let me fashion a work-around for now. The question is whether or not it can be done? Please let me know.

Thanks again for your attention to user questions/requests.

Evan
Hi Evan,

Your idea is clear. However, if implemented, it would be confusing to many users and thus cause us additional problems. This is why we'd rather wait and implement portfolio autotrading the way we've been planning to.

Best regards.

bauhinia
Posts: 31
Joined: 08 Sep 2011
Has thanked: 4 times
Been thanked: 2 times

Re: Portfolio Money Management and Autotrading

Postby bauhinia » 15 Nov 2011

Hi All,

Is there any further development on this concept?
As I am needing to implement it to manage my portfolio risk.

Cheers
Andrew

User avatar
JoshM
Posts: 2195
Joined: 20 May 2011
Location: The Netherlands
Has thanked: 1544 times
Been thanked: 1565 times
Contact:

Re: Portfolio Money Management and Autotrading

Postby JoshM » 17 Nov 2011

Is there any further development on this concept?
Which concept? Because this concept..
When I apply a strategy to autotrade 10 stocks with a maximum of, say, 15% of total equity per position (meaning max 6 positions at any given time if you expose 100% of your equity).
can be done with a shared list (from the ELCollections DLL or ADE [All Data Everywhere] dll) which holds the account value, and from where each position gets the current account equity * 15% to determine the position size.

For example, a function like the following will return the total equity for the whole portfolio:

Code: Select all

Inputs:
StartingAccountValue(NumericSimple), GetOrUpdate(StringSimple);

Variables:
AccountList(ListN.Share("FXAccValue")), accountValueOld(0);

once
accountValueOld = StartingAccountValue;

// Get the old account value
if ListN.Count(AccountList) > 0 then
accountValueOld = ListN.Back(AccountList);

// Get the current account value
if GetOrUpdate = "Get" then begin

FXEuroAccountValue = accountValueOld;

// Update account value with the last trade
end else if GetOrUpdate = "Update" then begin

profitOfTrade = PositionProfit(1);

// Update accountvalue
value1 = ListN.PushBack(AccountList, accountValueOld + profitOfTrade);

FXEuroAccountValue = 1; // dummy

end;
Regards,
Josh

ericvp
Posts: 30
Joined: 11 Jan 2012
Has thanked: 14 times
Been thanked: 6 times

Re: Portfolio Money Management and Autotrading

Postby ericvp » 04 Apr 2012

Hi,

I also have need for what Marina called "portfolio autotrading" back in June of 2008.

I've been using Portfolio Backtester for a handful of months to evaluate strategies involving about 100 instruments. In those evaluations, I've made use of portfolio level functions supplied by MultiCharts, such as Portfolio_NetProfit. I am now looking to begin autotrading with these strategies, and have a couple of questions:

(1) Has there been any forward progress by MultiCharts on what Marina called "portfolio autotrading" back in June of 2008? I see that something somewhat similar (MC-494 in the Project Management list) is a confirmed feature in MultiCharts 9.0.

(2) I understand the work-around helpfully suggested by JoshM earlier in this thread, at least as it could be used within Portfolio Backtester. But, how does one go about applying this to real money trading with a large number of instruments? Would I have to open 100 separate charts in MultiCharts? I haven't done any real money trading from within MultiCharts, and have been working almost exclusively with Portfolio Backtester (rather than with individual charts), so maybe I'm missing something obvious here. Is there a thread, resource, or tutorial that someone can point me to?

Thanks,
Eric

User avatar
Henry MultiСharts
Posts: 9165
Joined: 25 Aug 2011
Has thanked: 1264 times
Been thanked: 2957 times

Re: Portfolio Money Management and Autotrading

Postby Henry MultiСharts » 05 Apr 2012

Hi,

I also have need for what Marina called "portfolio autotrading" back in June of 2008.

I've been using Portfolio Backtester for a handful of months to evaluate strategies involving about 100 instruments. In those evaluations, I've made use of portfolio level functions supplied by MultiCharts, such as Portfolio_NetProfit. I am now looking to begin autotrading with these strategies, and have a couple of questions:

(1) Has there been any forward progress by MultiCharts on what Marina called "portfolio autotrading" back in June of 2008? I see that something somewhat similar (MC-494 in the Project Management list) is a confirmed feature in MultiCharts 9.0.

(2) I understand the work-around helpfully suggested by JoshM earlier in this thread, at least as it could be used within Portfolio Backtester. But, how does one go about applying this to real money trading with a large number of instruments? Would I have to open 100 separate charts in MultiCharts? I haven't done any real money trading from within MultiCharts, and have been working almost exclusively with Portfolio Backtester (rather than with individual charts), so maybe I'm missing something obvious here. Is there a thread, resource, or tutorial that someone can point me to?

Thanks,
Eric
Hello Eric,

We are working on the Portfolio Trading feature and would like to hear your thoughts and ideas regarding the visualization of the Portfolio Trading in the corresponding thread.

ericvp
Posts: 30
Joined: 11 Jan 2012
Has thanked: 14 times
Been thanked: 6 times

Re: Portfolio Money Management and Autotrading

Postby ericvp » 05 Apr 2012

Hi Henry,

Thanks for starting that thread. I posted my two cents.

In the meantime, what is the best way to go about implementing real trading for a 100 instrument strategy?

Thanks,
Eric

User avatar
Henry MultiСharts
Posts: 9165
Joined: 25 Aug 2011
Has thanked: 1264 times
Been thanked: 2957 times

Re: Portfolio Money Management and Autotrading

Postby Henry MultiСharts » 10 Apr 2012

Hi Henry,
Thanks for starting that thread. I posted my two cents.
In the meantime, what is the best way to go about implementing real trading for a 100 instrument strategy?
Thanks,
Eric
In MultiCharts you can trade from the main data series only.
You can base the calculation of your strategy on additional data series (ex. buy next bar at close of data2). If you would like to trade on 100 instruments at the same time-you need to create 100 charts.

ericvp
Posts: 30
Joined: 11 Jan 2012
Has thanked: 14 times
Been thanked: 6 times

Re: Portfolio Money Management and Autotrading

Postby ericvp » 10 Apr 2012

Hi Henry,

Thanks for the definitive reply.

Take care,
Eric


Return to “MultiCharts”