[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[EquisMetaStock Group] indicator assistance



PureBytes Links

Trading Reference Links

Hi All,
   
  I tried to construct the original wileder's ATR. 
   
  periods:=Input( "ATR Periods?",1, 200,200);
TH:=If(Ref(C, -1) > H,Ref(C,-1), H);
TL:=If(Ref(C, -1) < L,Ref(C,-1), L);
TR:=TH-TL;
Wilders(TR,periods)
   
  this is the original quote from stock charts "
   
  ============ ========= ========= ========= ========= ======
    
     The current High less the current Low.
  
     The absolute value of the current High less the previous Close.
  
     The absolute value of the current Low less the previous Close.

  If the current high-low range is large, chances are it will be used as the True Range. If the current high-low range is small, it is likely that one of the other two methods would be used to calculate the True Range. The last two possibilities usually arise when the previous close is greater than the current high (signaling a potential gap down or limit move) or the previous close is lower than the current low (signaling a potential gap up or limit move). To ensure positive numbers, absolute values were applied to differences. 
   
  Typically, the Average True Range (ATR) is based on 14 periods and can be calculated on an intraday, daily, weekly or monthly basis. For this example, the ATR will be based on daily data. Because there must be a beginning, the first TR value in a series is simply the High minus the Low, and the first 14-day ATR is the average of the daily ATR values for the last 14 days. After that, Wilder sought to smooth the data set, by incorporating the previous period's ATR value. The second and subsequent 14-day ATR value would be calculated with the following steps: 
    
     Multiply the previous 14-day ATR by 13.
  
     Add the most recent day's TR value.
  
     Divide by 14.

  Please rever to this website:
   
  http://stockcharts. com/school/ doku.php? id=chart_ school:technical _indicators: average_true_ range_a
   
   
  Somehow, I feel that my coding is wrong since it produced a rough ATR that similar to the one( a standard ATR - not wielder)  
   
  Can someone in this forum tell me the correct one? 
   
   
  regards
   
  Steve

       
---------------------------------
Yahoo!7 Mail has just got even bigger and better with unlimited storage on all webmail accounts. Find out more.
       
---------------------------------
Yahoo!7 Mail has just got even bigger and better with unlimited storage on all webmail accounts. Find out more.

[Non-text portions of this message have been removed]



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/equismetastock/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/equismetastock/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:equismetastock-digest@xxxxxxxxxxxxxxx 
    mailto:equismetastock-fullfeatured@xxxxxxxxxxxxxxx

<*> To unsubscribe from this group, send an email to:
    equismetastock-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/