[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [amibroker] Re: Portfolio Trading Module Request (6 parallel portfolios)



PureBytes Links

Trading Reference Links

Hi Fred, maybe the following new tool of mine could be of
some help here (you can find it in the latest ABtool release (v0.9.18)
just released some minutes ago):

xxTrader_Readme.txt:
---------------------------

xxTrader.exe v0.0.1 is only an experimental software.
It must be put into the ABtool directory.

Important: xxTrader requires the ABtool.dll v0.9.18 or higher.
You must put the full path to the AmiBroker\Plugins directory
into your PATH. Otherwise the DLL can't be used by xxTrader 
and xxTrader cannot start.

Under the "Tests" menu there is an entry for starting Fred Tonetti's
PORTFOLIO TRADER system (see file area of yahoo group amibroker).

Before starting PT via this program the following must be done:
  
  1) In AA the PT script must already be loaded and AA settings must already
     be done accordingly (see Fred's DOC)

  2) Before starting AA the following optional features (b..f) could be used:
     a) If there is a file ABtool/Systems/PT/DontStart.flg then this file will be deleted.
     b) If there is a file ABtool/Systems/PT/PreBat.bat then that file is started.
     c) If there is a file ABtool/Systems/PT/PreCmd.cmd then that file is started.
     d) If there is a file ABtool/Systems/PT/Script.js then that file is started.
     e) If there is a file ABtool/Systems/PT/Script.vbs then that file is started.
     f) If there is a file ABtool/Systems/PT/DontStart.flg then AA will NOT be started.

  3) As said in 2f AA will be invoked only if there is not a flag file 
     which signals not to start AA. This file could be created by one of the
     used batch or script files if there is reason to break the starting of AA,
     for example if some wrong external configuration data is detected by these
     scripts.

  4) The purpose of this is somehow to automate the whole testing and for doing more 
     tests by replacing some include files etc...
  
This software can also execute JScript and VBScript files (see its menu).

That's all folks! :-)
BTW, my own Backtester for Scoring&Ranking is unfortunately still not finished :-(

Uenal Mutlu
030609Mo
--
File available at the ABtool home site:
http://groups.yahoo.com/group/abtool

Uenal Mutlu (UM)
uenal.mutlu@xxxxxxxxxxx
abtool-owner@xxxxxxxxxxxxxxx



----- Original Message ----- 
From: "Fred" <fctonetti@xxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Monday, June 09, 2003 2:27 AM
Subject: [amibroker] Re: Portfolio Trading Module Request (6 parallel portfolios)


> Chuck,
> 
> One comment here with reagrds to your staement about multiple 
> versions of the AFL ... one of the things I have in the works is the 
> ability to have the scoring module that is included be a generic 
> include if you will that is referred to as @PT-SCORE.AFL and the 
> ability to roll different scoring mechanisms in and out of it w/o 
> having to modify the main AFL per se.  This coupled with having the 
> ability to have a "catalog" of scoring systems if you will with 
> possibly a form over the top of it which would allow PT to be run 
> without modification for lots of different situations.  All and all 
> this I believe is good direction to take but there are a variety of 
> wrinkles not the least of which is that #INCLUDE is a preprocessed 
> command which causes it to go and get what's in @PT-SCORE prior to 
> running any and all AFL commands regardless of where in the code they 
> occur which keeps me from using xxEXEC to copy a specific scoring AFL 
> on top of the common holding place.  Even #pragma nocache doesn't 
> solve this except for the second time that the AFL is run.  Also 
> since there is no ability to write statements like #INCLUDE filename 
> where filename is dynamically built this is another dead end.  The 
> only solution may be to have an outside VB or other form that is used 
> to drive the whole AFL process as it would then be in control and 
> could properly set things up prior to AFL excution, control the 
> execution and then deal with the results.
> 
> I know this doesn't directly deal with your desires but it does have 
> other benefits.  
> 
> As far as your request for having market neutral capability goes 
> within a particlar portfolio that is certainly doable but I need to 
> have an answer to my other question which is what to do with $ when a 
> sell/cover happens and there are no remaining ranked candidates to 
> chose from that have their "eyes" on a trade in the same market 
> direction as the one that was just exited.
> 
> As far as dealing with portfolios within portfolios go, given the way 
> I left the score function totally open it lends itself to whatever 
> one can dream up in terms of trading being long or short term and/or  
> long or short market direction.  It's conceivable in this framework 
> of SCORE now to for example write multiple timing systems and 
> multiple scoring criteria geared to the timing systems in one scoring 
> module each of which have an effect on what will be traded and when 
> and have the cream come to the top regardless of the investment 
> horizon and/or market direction.
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "Chuck Rademacher" 
> <chuck_rademacher@x> wrote:
> > I'll try to quickly comment on your questions and issues.   Like 
> you, I've
> > got a dozen things on the burner today and have to rush off.
> > 
> > I do run several systems in one portfolio and I do (using your 
> words) take
> > money out of the best performing system and give it to a system 
> that isn't
> > performing as well.   Just consider a long system and a short 
> system, for
> > instance.   I will never be able to find a "short" system that 
> makes as much
> > money as my worst "long" system.   But, I have to be short in order 
> to be
> > hedged.  That is the purpose of a hedge fund.    So, my objective 
> in running
> > several systems (long, short, fast, slow, etc.) is to smooth out 
> the equity
> > curve.
> > 
> > We can forget all of this, however, if we do something that you 
> (perhaps
> > accidentally) suggested.   We could run as many different versions 
> of your
> > software as we want (one per system) if we could merge the results 
> or append
> > to the files or had some way of consolidating the data into a singe 
> report.
> > That way, we could look at systems individually or combined.
> > 
> > I'm not sure about "b", but I invest exactly the same number of 
> dollars (or
> > beta dollars) in every stock, be it long or short.   If I have more 
> money, I
> > trade more stocks.  If I lose money, I trade fewer stocks.   If I 
> had $2
> > million to trade in a 100% hedged fund, I would be long about 
> $900,000 and
> > short about $900,000.  I don't use margin.   I could run two 
> versions of
> > your AFL, if I could then figure a way to combine the results.   
> I'm sure
> > that it can be done, I'm just not that familiar with Excel.
> > 
> > 
> >   -----Original Message-----
> >   From: Fred [mailto:fctonetti@x...]
> >   Sent: Sunday, June 08, 2003 6:02 PM
> >   To: amibroker@xxxxxxxxxxxxxxx
> >   Subject: [amibroker] Re: Portfolio Trading Module Request (6 
> parallel
> > portfolios)
> > 
> > 
> >   Chuck / b,
> > 
> >   b,
> > 
> >   I hate to answer questions with questions ... but ...
> > 
> >   I would not think one would want to arbitrarily take assets from
> >   portfolios that are doing well and put them in portfolios that are
> >   not doing so well, would they really ?  From a less complex point 
> of
> >   view I wrestled for awhile regarding how to rebalance the 
> investment
> >   dollars in individual portfolios since there are of course several
> >   ways to do this including an assumption that they were going to be
> >   rebalanced every bar.  This of course IMHO is not only not really
> >   feasible in real life it also contributes to the same sort of 
> thing
> >   i.e. punishing the winners and rewarding the losers.  What I opted
> >   for instead was a more realistic approach of rebalancing at the 
> time
> >   individual holdings were sold which is why even if one shoots for
> >   being 100% invested all the time there will at times be residual 
> cash
> >   in the account.
> > 
> >   Chuck,
> > 
> >   I would think in your case of professional money management that 
> this
> >   was not even be possible to do is it ? i.e. rob Peter to pay 
> Paul ...
> >   As far as being able to control what percentage is short or long 
> in a
> >   given portfolio I concur that this is probably worth doing 
> although a
> >   little esoteric and as you state not usable by most.
> > 
> >   Chuck / b,
> > 
> >   As far as the general concept goes of being able to manage 
> multiple
> >   portfolios that in turn utilize multiple scoring systems looking 
> at
> >   different Watch Lists, from a technical point of view it probably
> >   doesn't matter whether it's 2 or 200 portfolios, but to get a 
> better
> >   idea of whether or not this is even a road I want to consider 
> going
> >   down I'd like each of to think about what you really want in this
> >   area.
> > 
> >   For example does each Portfolio need to be looking at different 
> Watch
> >   Lists ? is each one going to utilize different scoring ? etc etc.
> > 
> >   My initial overly simplistic thought in this area is that if the
> >   answers to all the above and other questions are all true, then 
> why
> >   not just set up different PT runs each of which is used to deal 
> with
> >   the investment philosiphy of the individual portfolio ?  Except 
> for
> >   the concept of being able to move $ from one portfolio to another
> >   this flies and again I question the viability of doing this.
> > 
> >   Looking forward to your responses.
> > 
> >   Fred
> > 
> >   --- In amibroker@xxxxxxxxxxxxxxx, "Chuck Rademacher"
> >   <chuck_rademacher@x> wrote:
> >   > Yes, b, I would like to see your suggestion implemented and yes 
> it
> >   does
> >   > adequately solve my problem as well.   A much better approach to
> >   solving the
> >   > problem.
> >   >
> >   > Of course, you and/or I could add this capability to Fred's code
> >   ourselves.
> >   > But this does raise some issues.    If we can convince Fred 
> that an
> >   idea has
> >   > merit and if he implements it, it is shared by everyone.    
> Another
> >   option
> >   > is for one of us to make the modifications and submit them to 
> Fred
> >   to see if
> >   > he is happy to add our code to his.   The final option is that 
> we
> >   make the
> >   > changes, perhaps share it with others, but it doesn't become 
> part
> >   of the
> >   > official release of Fred's work.  The downside to this is that 
> if
> >   Fred makes
> >   > other improvements, anyone using "our" work doesn't benefit from
> >   Fred's
> >   > subsequent improvements.
> >   >
> >   > Fred, we would appreciate your views on this subject.
> >   >   -----Original Message-----
> >   >   From: b519b [mailto:b519b@x...]
> >   >   Sent: Sunday, June 08, 2003 5:22 PM
> >   >   To: amibroker@xxxxxxxxxxxxxxx
> >   >   Subject: [amibroker] Portfolio Trading Module Request (6 
> parallel
> >   > portfolios)
> >   >
> >   >
> >   >   Fred,
> >   >
> >   >   While you are thinking about Chuck's suggestion, here is a 
> closely
> >   >   related one. In fact, if the following were implemented, it 
> would
> >   >   also address most or all of Chuch's desire.
> >   >
> >   >   I would like to be able to test the "interaction" of up to 6
> >   methods
> >   >   running in parrallel which share profit and loss. For 
> example, I
> >   >   would like to be able to "split" my funds into 6 parts. For my
> >   >   purposes, equal size parts would be fine, but I see Chuck 
> hoping
> >   for
> >   >   variable size parts.
> >   >
> >   >   Each part would have its own ranking system. The parts
> >   >   would "interact" in the sense that and losses from each part 
> would
> >   >   be shared by all the parts equally. If part A made 120K and 
> part B
> >   >   lost 60K and the other parts finished even, then all the parts
> >   would
> >   >   continue on with an extra 10K each. Exactly how to implement
> >   >   this "redistribution" or "rebalancing" is not all that 
> important
> >   to
> >   >   me. It could be done dynamically so it redistributes total 
> equity
> >   >   (everytime a trade is exited). Or it could be done at the end 
> of
> >   >   every month (mid trade changes in trade size could be tough to
> >   >   code). Or in some other way.
> >   >
> >   >   Users could choose to define the ranking system for each part 
> for
> >   >   their own purposes. One person might define the ranking such 
> that
> >   >   the same market timing signal is used by all 6, but a 
> different
> >   >   selection stragey is used; perhaps 3 long and 3 short 
> strategies.
> >   >   Another user might use a single long and single short 
> selection
> >   >   strategy, but use 3 different timing signals for each.
> >   >
> >   >   What do you think? Is this technically possible to add to
> >   Portfolio
> >   >   Trading? Or, will it be took complex or too slow?
> >   >
> >   >   Why did I suggest 6 parts or portfolios? Because I think I 
> would
> >   >   like to test 4 (2 long and 2 short), so 6 would give some 
> room to
> >   >   grow if I later get curious about 3 each way. Now that I 
> think of
> >   >   it, why not give the user the option of up to 10 parts. That
> >   should
> >   >   satisfy even the most creative thinkers.
> >   >
> >   >   b
> >   >
> >   >   --- In amibroker@xxxxxxxxxxxxxxx, "Chuck Rademacher"
> >   >   <chuck_rademacher@x> wrote:
> >   >   > Fred, I am enjoying working with your PT software.   
> Especially
> >   >   once I got
> >   >   > over a few problems of my own doing.   I was too anxious and
> >   didn't
> >   >   > thoroughly read all of the documentation.
> >   >   >
> >   >   > I may be the only person interested in the feature that I am
> >   going
> >   >   to
> >   >   > propose.  In which case, it will probably just sit on the 
> back
> >   >   burner for a
> >   >   > while.   I suppose that there is no good reason why I can't 
> make
> >   >   the
> >   >   > necessary changes myself, but it would be better if it 
> became
> >   part
> >   >   of the
> >   >   > officially available version.
> >   >   >
> >   >   > Most of my trading must be 100% hedged.   If I'm long $100,
> >   then I
> >   >   must be
> >   >   > short $100.   It would be great, therefore, if I could 
> impose a
> >   >   limit on the
> >   >   > number of positions and/or dollars for longs and shorts.   
> Of
> >   >   course, it
> >   >   > would be nice if I could adjust those numbers dynamically.
> >   Some
> >   >   of the
> >   >   > funds I manage allow me to be between 25% and 75% long.
> >   >   >
> >   >   > Thanks for your consideration and thanks too for sharing 
> your
> >   >   efforts with
> >   >   > the rest of us.
> >   >
> >   >
> >   >         Yahoo! Groups Sponsor




------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get A Free Psychic Reading! Your Online Answer To Life's Important Questions.
http://us.click.yahoo.com/Lj3uPC/Me7FAA/ySSFAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/