Line Chart With price field for Amibroker (AFL)
ameheta almost 10 years ago Amibroker (AFL)
Line Chart With price field. Line char is gives clear visual trend than candle stick chart.
Screenshots
Indicator / Formula
Copy & Paste Friendly
_SECTION_BEGIN("1. Line Chart With price Field");
SetChartOptions(0,chartShowArrows|chartShowDates);
_N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) ));
yprice = ParamField("Price Field", 3);
/*0 - returns Open array
1 - returns High array
2 - returns Low array
3 - returns Close array (default)
4 - returns Average array = (H+L+C)/3
5 - returns Volume array
6 - returns Open Interest array
*/
Plot( yprice, "Close", IIf(C > Ref(C, -1), colorGreen, IIf( C < Ref(C,-1), colorRed, colorDefault)), styleNoTitle | styleLine );
_SECTION_END();1 comments
Leave Comment
Please login here to leave a comment.
good one