Small code for Money Management. Trade based on money, not lots

Forums ProRealTime English forum ProOrder support Small code for Money Management. Trade based on money, not lots

Viewing 3 posts - 1 through 3 (of 3 total)
  • #117149

    Good morning, I would like to present the small code that I use to compare the performance of a system on different instruments.

    It is based on the fact that normally when we operate in a system we do it based on the money available to do so, but each index has its own value, so at best, a NASDAQ system can apparently generate less performance than a DJI system. But the investment for each lot in NASDAQ is € 425 / lot and in DJI it is € 1400 / lot.

    With this small code I seek to “normalize” the return on investment based on money invested and not in batches.
    What we do is allocate the amount of money we want in the system and the price that each contract has. This function is responsible for assigning the quantity of lots to approximate that quantity (with a decimal)

    At first look we can buy returns and DD for every € 1000 of investment, for example.

    To the administrators: in the forum I did notfind a code of this type, if there is one, you can delete this entry without problem. I do not intend to duplicate content.

    Greetings.

     

     

     

    1 user thanked author for this post.
    #117167

    There are some money management snippets, but this seems a bit different.

    I hope many users will find it beneficial. Any suggestion and/or improvement is highly welcome, as always on our forums.

    Thank you for sharing your idea! 🙂

     

    #117173

    Couldn’t LOTPRICE just be CLOSE?

    The downside to this sort of lot size calculation is that inflation is not considered. $1000 back in the 1970’s was worth far more than it is today and stock prices were far lower. So to buy $5000 worth of the Dow Jones back in the 1979’s you would need to have a lot size of somewhere around $9 whereas to buy the same amount today it would be just 20 cents. To keep a constant we would need to add some sort of inflation into our calculation which is not possible.

    In reality just buying a lot size based on a % of an index price will work better over time.

    The attached image is created using this indicator of your code:

     

     

Viewing 3 posts - 1 through 3 (of 3 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login