AmiBroker formula Language

Code:
/*
 Modified from http://www.amibroker.com/library/detail.php?id=100, by Steve iser - [email protected] 
 Modified by TohMz  on June 9th, 2008 
*/ 
SetChartOptions( 0, chartShowArrows|chartShowDates ); 

_SECTION_BEGIN("Price Chart"); 
_N(Title = StrFormat("{{NAME}}- {{INTERVAL}} {{DATE}} O= %g, H= %g, L= %g, C= 
  %g (%.1f%%) V= " +WriteVal( V, 1.0 ) +"\n{{VALUES}}", O, H, L, C, SelectedValue(ROC( C, 1 )) )); 
  PriceStyle = GetPriceStyle(); 
  PriceStyleOpt = ParamStyle("Price Style")|PriceStyle; 

  if (PriceStyle==styleCandle) 
     Plot( C, "", colorBlack,  PriceStyleOpt); 
  else 
     Plot( C, "", IIf( Close >= Ref(C, -1), colorBlue, colorRed ), 
  PriceStyleOpt); 
  _SECTION_END(); 

  _SECTION_BEGIN("BW Alligator"); 
  /*** The trend indicators ***/ 

  P= ParamList("Price", "Close|(H+L)/2|(H+C+L)/3",1); 

  if (P=="Close") 
     A = C; 
     
  else 
  if (P=="(H+C+L)/3") 
     A = (H+C+L)/3; 
  else 
    A = (H+L)/2; 

  AlligatorJaw   = Ref(Wilders(A,13),-8); 
  AlligatorTeeth = Ref(Wilders(A,8), -5); 
  AlligatorLips  = Ref(Wilders(A,5), -3); 

  Plot(AlligatorJaw,  "Jaw", ParamColor("Jaw's Color",colorBlue), 
  ParamStyle("Jaw's Style", styleThick)); 
  Plot(AlligatorTeeth,"Teeth", ParamColor("Teeth's Color",colorRed), 
  ParamStyle("Teeth's Style", styleThick)); 
  Plot(AlligatorLips, "Lips", ParamColor("Lips's Color",colorGreen), 
  ParamStyle("Lips's Style", styleThick)); 

  _SECTION_END(); 


  _SECTION_BEGIN("BW Fractal"); 

  UpFractal= ValueWhen( 
    (Ref(H,-2) > Ref(H, -4)) AND 
    (Ref(H,-2) > Ref(H, -3)) AND 
    (Ref(H,-2) > Ref(H, -1)) AND 
    (Ref(H,-2) > H), Ref(H,-2)); 

  DownFractal= ValueWhen( 
    (Ref(L,-2) <= Ref(L, -4)) AND 
    (Ref(L,-2) <=  Ref(L, -3)) AND 
    (Ref(L,-2) <=  Ref(L, -1)) AND 
    (Ref(L,-2) <=  L), Ref(L,-2)); 



  //== Added Crash  crashandburn59 [at] hotmail.com solution 
  Plot(Ref(UpFractal,2), "Up Fractal", ParamColor("Up Fractal Color",colorRed), 
  ParamStyle("Up Fractal Style", styleDashed)); 
  Plot(Ref(DownFractal,2), "Down Fractal",ParamColor("Down Fractal 
  Color",colorBlue), ParamStyle("Down Fractal Style", styleDashed)); 

  //Plot(Max(HHV(H,3),Ref(UpFractal,2)), "Up Fractal", ParamColor("Up Fractal Color",colorRed), ParamStyle("Up Fractal Style", styleDashed)); 
  //Plot(Max(HHV(H,3),Ref(UpFractal,2)), "Down Fractal",ParamColor("Down FractalColor",colorBlue), ParamStyle("Down Fractal Style", styleDashed)); 

  _SECTION_END();
 
Hi,
Who is good data supplier for intraday live.
Here already many of you should be using live data with amibroker.
I am also interested to use amibroker and live data feed for f&o. Which supplier is good.
Appreciated for your comments.
regards,
anjanbm

Note: sorry if posted in this thread
 

msa5678

Well-Known Member
Hi,
Who is good data supplier for intraday live.
Here already many of you should be using live data with amibroker.
I am also interested to use amibroker and live data feed for f&o. Which supplier is good.
Appreciated for your comments.
regards,
anjanbm

Note: sorry if posted in this thread


""""xFeeds""" Charges are around 700 pm. Almost all the Stocks are Covered . Futures also for almost all Stocks. Options data also available. Sometimes their server is down , and you miss an entier days data. But this is not frequent. Happened , once in the past 6 months. Backfill is only for one month.

""""IB"""""Charges around 700 pm. Almost all the Stocks and Futures covered. No options data. Backfill for 6 months. But feed becomes slow when backdata is more than 3 months. Yesterday their feed was down for 1 full day, today they started the feed but yesterday's data is missing. They don't even feel necessary to inform the users of the fault.

""""GDFL""""Charges around 1350pm for the least version. Looks like the most professional Data Provider in India. Problem is they don't provide Spot Data. They have only Futures and Options Data. They were going to start Spot Data this week. Am not aware of the developments since 15th Dec.

Ofcourse there are many free data providers. But who will risk 50k to save 1k.

 
Dear Friends,
Can anyone make an exploration and scan afl with fractal chaos band, which will scan the stocks near to the upper band and near to the lower band on any time frame real time as well as eod.

Thanks in advance.
 
Hello Everyone,

I dont know how to write a program for backtesting , can someone please write it for me.

The strategy is simple,
Buy on any give date, sell it as soon as you get 1% or 2% profit , In case the price falls down by more than 3%, buy one more of the same share, to average it . if it doesnt wait till you get your price.
 

Similar threads