array variables availability in ProRealTime – examples and discussions

Forums ProRealTime English forum ProBuilder support array variables availability in ProRealTime – examples and discussions

Viewing 15 posts - 151 through 165 (of 255 total)
  • #168725

    I would like to know if the platform has been implemented with arrays

     

    #168726
    #168757

    Grazie

    Thank you

     

    #170399

    Good evening, it would be possible to have a matrix?

    For example:

    $example[1,3]=arrayvalue13

    #170400

    Currently arrays have only 1 dimension, so no that’s not possible to build matrix.

    #173690

    Hi

    I have begun to see a couple of systems that are self optimising and I feel like they may be using arrays (I may be wrong) based on the examples on the forum

    If for example I wanted to go long when the EMA[8] cross the SMA[X], where X is the variable giving the most profitable outcome based on the last 500 bars, can I use arrays to find X? So my system could be self optimising for X as it ran rather than using a fixed value

    Thanks

    Ruark

    #174931

    Hi Ruark (@Robo Futures Trader), I’ve tried this manually using Python:

    1. backtest strategy over different historical samples (e.g. 4hr strategy, monthly samples, over 5 yrs)
    2. for each sample, optimise variables to find best gain (or other parameter, I personally like gain / drawdown)
    3. save optimum variables for each sample, together with some ‘average characteristic’ parameters to identify market conditions (trend strength, volatility etc)
    4. take results from python and then manually (Excel) plot optimum vars Vs ‘average characteristic’ parameters to look for trends
    5. curve-fit a function for each variable, for example, var1 = function of (macdline, or adx) could be a simple linear function, y = mx + c
    6. code the functions into the strategy to optimal adjust parameters based on market conditions

     

    For the single strategy/example I tried, it seems to work and creates what appears to be an adaptive and more robust strategy… but to be honest it’s so much manual work that I gave up (day job, family, not enough time).

    The next step in this journey was going to be using python to do the curve fitting automatically (steps 4,5 above) to identify best functions. As an engineer, this parameter curve-fitting process feels like a good direction to move in. I think the benefit could be a simpler strategy that it adapts to future changes in the market.

    It would be great (@Nicolas ?) if PRT could do steps 1,2,3 above during a walkforward analysis. That would save a lot of time. Even better of PRT could do the whole process (1-6) 🙂

    Also, it would be great if someone else has already worked out how to self-optimise in PRT.

    Perhaps I’m going down the wrong track but I’ve not managed to develop a robust code using walkforward and most of my short-time-frame strategies are over-fitted. Basic daily strats are ok.  BTW, I could really use a tutorial/lesson on how to develop a robust code using walkforward and then also how to actually manage the process during live running. Can you make a youtube video with the basics?

    thanks all and hope to continue this discussion!

     

    #177743
    Maa

    Hi,

    I am trying to test the third example from page one (Example #3: separate buy/sell volumes on the same candle). I am not able to get it to work however, I only see a horizontal line with the value zero as shown in the picture.

    Any ideas what might be causing this?

    #177768

    It will not plot anything for the data history, but only with live data on each received tick.

    1 user thanked author for this post.
    avatar Maa
    #177812
    Maa

    Hi Nicolas,

    Yes but I am not able to see the live ticks either (like the bars in the picture you posted with the code).

    I don’t know if I am missing something. I am adding the indicator as shown in the picture and I am using IG as broker.

    #177817

    Insert at line 4: once $upvol[0]=0, once $dnvol[0]=0 to reinstate previous behaviour

    1 user thanked author for this post.
    avatar Maa
    #177825
    Maa

    Great, now it is working!

    Thanks!

    #179234

    Apologies if this has been asked already but I have been unable to find it, if it has.

    Is there the ability to sort the contents of an array yet?

    Thanks

    Rob

    #179235

    Will be possible in a few days for ProRealTime software, then updates with new instructions will come to other versions dealed by brokers. I’m currently testing these new capabilities (with other many cool new instructions and not specific to arrays..).

    The new instructions for arrays are:

    Unset($var) Reset the whole array

    ArraySort($var,mode) Sort ASCEND or DESCEND (mode) the whole data set of an array

     

    2 users thanked author for this post.
    #184268

    Hi,

    Is it possible to initialize an array with only one line?

    Let’s take this example :

    Could it be replaced by

    or something similar?

    In my actual example, I have a llllooooonnnnnngggg list of values to initialize the array with.

    Thanks in advance,

    Nicolas

Viewing 15 posts - 151 through 165 (of 255 total)
Similar topics:

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