Système basé sur croisement Stochastique

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #113124 quote
    Maria PRTMaria PRT
    Moderator
    Average

    Ci-dessous une demande qui a été envoyée à ProRealTime :

    Bonjour,
    L’indicateur utilisé est le stochastique simple réglé en 5/3/3 mais sur 3 ut différentes.
    Objectif : détecter un croisement de stochastique sur 1mn mais en respectant des conditions sur 5 et 30 mn.
    Conditions signal ACHETEUR :
    1/ UT 30 minutes : %K et %D ont croisé à la hausse sous la valeur 50 (%K se situe au-dessus de %D)
    2/ UT 5 minutes : %K et %D ont croisé à la hausse sous la valeur 50 (%K se situe au-dessus de %D)
    3/ UT 1 minute : %K < valeur 25
    4/ UT 1 minute : %K croise à la hausse %D
    Conditions signal VENDEUR :
    1/ UT 30 minutes : %K et %D ont croisé à la baisse sous la valeur 50 (%K se situe au-dessous de %D)
    2/ UT 5 minutes : %K et %D ont croisé à la baisse sous la valeur 50 (%K se situe au-dessous de %D)
    3/ UT 1 minute : %K > valeur 75
    4/ UT 1 minute : %K croise à la baisse %D

    Et une proposition de réponse :

    DEFPARAM CUMULATEORDERS=false
    
    timeframe (5 minutes)
    StochK5mn=Stochastic[5,3](close)
    StochD5mn=Stochasticd[5,3,5](close)
    
    c5mnachat=StochK5mn > StochD5mn and StochK5mn<50
    c5mnvente=StochK5mn < StochD5mn and StochK5mn<50
    
    timeframe(30 minutes)
    StochK30mn=Stochastic[5,3](close)
    StochD30mn=Stochasticd[5,3,5](close)
    
    c30mnachat=StochK30mn < StochD30mn and StochK30mn<50
    c30mnvente=StochK30mn < StochD30mn and StochK30mn<50
    
    timeframe(default)
    StochK1mn=Stochastic[5,3](close)
    StochD1mn=Stochasticd[5,3,5](close)
    
    c1mnachat=StochK1mn < 25 and StochK1mn crosses over StochD1mn
    c1mnvente=StochK1mn > 75 and StochK1mn crosses under StochD1mn
    
    if c1mnachat and c5mnachat and c30mnachat then
    buy 1 share at market
    elsif c1mnvente and c5mnvente and c30mnvente then
    sellshort 1 share at market
    endif
    Nicolas thanked this post
    #113143 quote
    JC_BywanJC_Bywan
    Moderator
    Master

    Bjr, lignes 5,12,19 en 5,3,5 vs requête utilisateur en 5,3,3? Soit typo dans la requête, soit lignes 5,12,19 à modifier en 5,3,3?

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.
ProRealAI ProRealAI New

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTime™ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

Système basé sur croisement Stochastique


ProOrder : Trading Automatique & Backtests

New Reply
Author
author-avatar
Maria PRT @maria-prt Moderator
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by JC_BywanJC_Bywan
7 years ago.

Topic Details
Forum: ProOrder : Trading Automatique & Backtests
Language: French
Started: 11/19/2019
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...