Ok so I am trying to learn to use Multicharts. Essentially my main interest if using multicharts to backtest my strategies. Now writing the actual entry and exit signals for my strategies is ok. However I am having issues finding information on the "money management" functions and PMM Keyworks.
Essentially I want to code the following but I have no idea where to start:
- Max number of positions (either long or short) = 5
- Certain criteria to define the size of the position depending on the available funds in my account
So to make things clearer I want the system to first check how many positions I already have open and then decide on how many more positions I can open. Then I want the system to find the next appropriate stock based on the criteria of my strategy and then based on position rules, calculate how many shares it is allowed to buy(or sell) for this particular stock.
did you go through the two PDFs that MC provides? One contains an explanation of the Portfolio Trader functionality and reserved words, the other goes through the three built in Portfolio Strategies and explains the code.
This is a good start and should give you the information you are looking for.