Feedback loop of prevailing market conditions

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #192009 quote
    deletedaccount051022
    Participant
    New

    Hi,

    Within a strategy I wish to capture the prevailing market conditions at the time that a trade is open, such as volatility, volume and so on, with a view to feeding this back into the algo to identify the current prevailing market cylcle or change thereof.  From this an algo could recognise what cycle the market is entering into (eg strong bull, range bound) and use a different set of stored parameters for the next trade.

    For example, an algo goes long and after the position is opened the volatility begins to increase and the volume reduces.  The next trade the aglo should take would use a more cautious set of parameters (a tighter stop loss, a smaller target profit, a shorter linear regression lookback period etc.)

    Is this type of monitoring and feedback possible?   The code I am currently using monitors Standard Deviation up to the point a position is opened.  If volatility spikes during an open position then the same STD calculation used for the next trade should be on a shorter lookback period.

    Thanks very much

    #192024 quote
    phoentzs
    Participant
    Master

    What speaks against it, simply starting several algos with different settings such as: large/small SL, large/small TP, faster/slower trailing stop, etc., in parallel and thus dividing the risk?

    #192028 quote
    deletedaccount051022
    Participant
    New

    Hi phoentzs

    Thanks for your suggestion.   To do as you suggest I believe that I would need to run 3x the risk.  Might work but am ideally looking for a loopback.

    Alternatively I could manually run a re-optimise on a regular basis, but you need to stop and re-start.

    Thanks

    #192029 quote
    GraHal
    Participant
    Master

    need to stop and re-start.

    I do this and record  – in the ‘Notes for the System’ – a brief summary of performance up to when I stopped to reoptimise (over a weekend usually).

    thanked this post
    #192034 quote
    phoentzs
    Participant
    Master

    @samsampop

    why triple risk? Spread the position size across all systems. So it’s basically the same risk as having the full position size in just one system. That’s why I like to use SP500, small margin, small spread.

    thanked this post
    #192065 quote
    JS
    Participant
    Senior
    DefParam CumulateOrders = False
    
    NormSTDPerc = Std[20](Close) / Close * 100
    If NormSTDPerc > 0.2 and NormSTDPerc < 0.4 then
    LookBackPeriod = 20
    ElsIf NormSTDPerc > 0.4 and NormSTDPerc < 0.8 then
    LookBackPeriod = 10
    EndIf
    
    If Close > Average[LookBackPeriod](Close) then
    Buy 1 contract at Market
    EndIf
    
    If Close < Average[LookBackPeriod](Close) then
    SellShort 1 contract at Market
    EndIf
    
    Hi @samsampop

    You can normalize the standard deviation (NormSTDPerc = Std[20](Close) / Close * 100) and when the normalized standard deviation falls between certain boundaries, link these boundaries to, for example, the LookBackPeriod…

    #192086 quote
    deletedaccount051022
    Participant
    New
    Hi JS Thank you, it gives me an idea of solving this a different way.  Much appreciated.
Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.

Feedback loop of prevailing market conditions


ProOrder: Automated Strategies & Backtesting

New Reply
Summary

This topic contains 6 replies,
has 4 voices, and was last updated by deletedaccount051022
3 years, 10 months ago.

Topic Details
Forum: ProOrder: Automated Strategies & Backtesting
Language: English
Started: 04/21/2022
Status: Active
Attachments: No files
Logo Logo
Loading...