TradingWolf

TradingWolfLibary

TradingWolf Atualizado   
Library "TradingWolfLibary"

getMA(int, string)
  Gets a Moving Average based on type
  Parameters:
    int: length The MA period
    string: maType The type of MA
  Returns: A moving average with the given parameters

minStop(float, simple, float, string)
  Calculates and returns Minimum stop loss
  Parameters:
    float: entry price (Close if calculating on the entry candle)
    simple: int Calculate how many bars back to look at swings
    float: Minimum Stop Loss allowed (Should be x 0.01) if input
    string: Direciton of trade either "Long" or "Short"
  Returns: Stop Loss Value
Notas de Lançamento:
v2

Added:
minmaxStop(float, simple, float, float, string)
  Calculates and returns Minimum/Maximum stop loss
  Parameters:
    float: entry price (Close if calculating on the entry candle)
    simple: int Calculate how many bars back to look at swings
    float: Minimum Stop Loss allowed (Should be x 0.01) if input
    float: Maximum Stop Loss allowed (Should be x 0.01) if input
    string: Direciton of trade either "Long" or "Short"
  Returns: Stop Loss Value
Notas de Lançamento:
v3

Updated:
minmaxStop(float, simple, float, float, string)
  Calculates and returns Minimum/Maximum stop loss
  Parameters:
    float: entry price (Close if calculating on the entry candle)
    simple: int Calculate how many bars back to look at swings
    float: Minimum Stop Loss allowed (Should be x 0.01) if input
    float: Maximum Stop Loss allowed (Should be x 0.01) if input
    string: Direciton of trade either "Long" or "Short"
  Returns: Stop Loss Value
Notas de Lançamento:
v4

Added:
tpCalc(float, float, float, string)
  Calculates the take profit value
  Parameters:
    float: entry price (Close if calculating on the entry candle)
    float: stop would be the variable calculated just before your TP, you can use the minmaxStop
    float: ratio is a reward multiplier
    string: direction is the direction of the trade
Notas de Lançamento:
v5
Notas de Lançamento:
v6
Notas de Lançamento:
v7

Added:
atrStop(_entry, _risk, _direction)
  Calculates the Stop Loss using ATR
  Parameters:
    _entry
    _risk
    _direction
  Returns: Take proit value

atrTake(_entry, _reward, _direction)
  Calculates the Take profitusing ATR
  Parameters:
    _entry
    _reward
    _direction
  Returns: Take proit value
Notas de Lançamento:
v8 changed if statement bug

Biblioteca do Pine

No verdadeiro espírito TradingView, o autor publicou este código de Pine como uma biblioteca de código aberto para que outros programadores de Pine de nossa comunidade possam reutilizá-lo. Um brinde ao autor! Você pode usar esta biblioteca em particular ou em outras publicações de código aberto, mas a reutilização deste código em uma publicação é regida pelas Regras da Casa.

Aviso legal

As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.

Gostaria de usar essa biblioteca?

Copie a seguinte linha e cole-a em seu script.