miércoles, 28 de septiembre de 2016

la sorgente del ts 50%

//__________________________________________Tecnica 50%________________________//


Var: newday(false), mioopen(0), miomin(0), miomax(0), mioclose(0),dvsup,dvmed,dvinf;
Var: wmax,wmin,wmed,DMAX,DMIN;

newday=GetValues(days,1,mioopen,miomin,miomax,mioclose);
dvsup= miomin+(261.8*(miomax-miomin))/100;
dvmed= miomin+(50*(miomax-miomin))/100;
dvinf= miomax-(261.8*(miomax-miomin))/100;

if isfirstbarday then
   WMAX=H;
   WMIN=L;
   else
   WMAX=iif(H>=WMAX[1],H,WMAX[1]);
   WMIN=iif(L<=WMIN[1],L,WMIN[1]);
   WMED=wmax-(wmax-wmin)*0.5;
endif;
PlotChart(WMED,0, gray, dot, 1);
////////////////////////////////////////////////////////////////////////////////////////////////
installstoploss(inperc,3.00,"SL", STARTNEXTBAR);
plotchartNoZero(getstoploss, 0, red, solid, 2);
DrawText(NEWOGG,0 , D,getstoploss , "sl",getstoploss , black, 25, 1+4,Alright);
///////////////////////////////////////////////////////////////////////////////////////////////////

if  c<dvsup and c>highd(1) and GetNumOpEnterLongToday=0 then enterlong( nextbar,atopen);endif;
if positiondir=1 and c<dvmed then exitlong(nextbar,atopen);endif;


if c>dvinf and c<lowd(1) and GetNumOpEntershortToday=0 then entershort( nextbar,atopen);endif;
if positiondir=-1 and c>dvmed then exitshort(nextbar,atopen);endif;


plotchart(dvsup,0,green,dot,1);
plotchart(dvmed,0,white,solid,1);
plotchart(dvinf,0,red,dot,1);


2 comentarios:

 era dal 26 marzo che i sistemi non si posizionavano long...oggi lo han fatto...area 21.90 posizionano il 1º take profit