Stock Portfolio Organizer
The ultimate porfolio management solution.
Shares, Margin, CFD's, Futures and Forex
EOD and Realtime
Dividends and Trust Distributions
And Much More ....
WiseTrader Toolbox
#1 Selling Amibroker Plugin featuring:
Advanced Adaptive Indicators
Advanced Pattern Exploration
Neural Networks
And Much More ....
Get Price for Amibroker (AFL)
Copy & Paste Friendly
Back
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | GraphXSpace = 5 ; SetChartOptions (0, chartShowArrows | chartShowDates ); Plot ( C , "Close" , colorBlack , styleNoTitle | ParamStyle ( "Style" ) | GetPriceStyle () ); /* This code calculates the previous day's High and Low */ Hi1 = IIf ( Day ()!= Ref ( Day (),-1), Ref ( HighestSince ( Day ()!= Ref ( Day (),-1), H ,1),-1),0); Hi = ValueWhen ( Day ()!= Ref ( Day (),-1),Hi1,1); Lo1 = IIf ( Day ()!= Ref ( Day (),-1), Ref ( LowestSince ( Day ()!= Ref ( Day (),-1), L ,1),-1),0); Lo = ValueWhen ( Day ()!= Ref ( Day (),-1),Lo1,1); Cl1 = IIf ( Day ()!= Ref ( Day (),-1), Ref ( C ,-1),0); C1 = ValueWhen ( Day ()!= Ref ( Day (),-1),Cl1,1); numbars = LastValue ( Cum ( Status ( "barvisible" ))); fraction= IIf ( StrRight ( Name (),3) == "" , 3.2, 3.2); hts = -33.5; YHL = ParamToggle ( "Yesterday Hi Lo" , "Off|On" ,1); if (YHL==1) { YH = Hi; YHI = LastValue (YH,1); YL = Lo; YLI = LastValue (YL,1); Plot (YL, "" , colorBrightGreen , styleLine | styleNoRescale ); Plot (YH, "" , colorBrightGreen , styleLine | styleNoRescale ); PlotText ( " YH = " + WriteVal (YH,fraction), LastValue ( BarIndex ())-(numbars/Hts), YHI, colorBrightGreen ); PlotText ( " YL = " + WriteVal (YL,fraction), LastValue ( BarIndex ())-(numbars/Hts), YLI, colorBrightGreen ); } /* This code calculates Todays High AND Low */ _SECTION_BEGIN ( "Hi and LO of the day" ); TLH = ParamToggle ( "Days Hi Lo" , "Off|On" ,1); if (TLH==1) { Hodcolorsheme= ParamColor ( "High of day color" , colorDarkRed ); LodColorscheme= ParamColor ( "Low of day color" , colorDarkRed ); tempnum = TimeNum (); temphi[0] = H [0]; temphiColor[0] = Hodcolorsheme; templo[0] = L [0]; temploColor[0] = LodColorscheme; for ( i = 1; i < BarCount ; i++ ) { if (tempnum[i] - tempnum[i-1] > Interval ()) { if ( H [i] > temphi[i-1]) { temphi[i] = H [i]; temphiColor[i] = Hodcolorsheme; } else { temphi[i] = temphi[i-1]; temphiColor[i] = Hodcolorsheme; } if ( L [i] < templo[i-1]) { templo[i] = L [i]; temploColor[i] = LodColorscheme; } else { templo[i] = templo[i-1]; temploColor[i] = LodColorscheme; } } else { temphi[i] = H [i]; temphiColor[i] = Hodcolorsheme; templo[i] = L [i]; temploColor[i] = LodColorscheme; } } Plot (temphi, "" , temphiColor, styleBar ); Plot (templo, "" , temploColor, styleBar ); } _SECTION_END (); |