Trade Arrows not aligned correctly

I somehow managed to change things so the trade arrows do not display properly. Can anyone tell me how to get the arrows to align properly?

Thanks!

Trade Arrows|690x287

@DanaF,

I think the flux capacitor needs tuning. Try the left handed wrench.

Seriously, without code or settings, we have NO IDEA what you need.

The photo might be helpful, but without code to see where the arrows should be, I have no idea how to help.

Please remember to use code tags when you post code.

1 Like

The code does not have arrow plots. It just has buy and sell signals. The chart used to display the arrows correctly, but I messed around with the chart and now it doesn't. I just may have to reinstall Ami.

@DanaF, before doing that, try to restore the original code.
Looking at your image, it seems the chart produced by the standard "Price.afl" formula.

You probably moved the MA section before the Plot( C, "Close", ... line, so the "automatic" trade arrows are now positioned around to the MA line instead of using the OLHC candles values.

Anyway, the original formula looks like this:

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 ) ) ));
Plot( C, "Close", ParamColor("Color", colorDefault ), styleNoTitle | ParamStyle("Style") | GetPriceStyle() );

_SECTION_BEGIN("MA");
P = ParamField("Price field",-1);
Periods = Param("Periods", 15, 2, 300, 1, 10 );
Plot( MA( P, Periods ), _DEFAULT_NAME(), ParamColor( "Color", colorCycle ), ParamStyle("Style") ); 
_SECTION_END();

Thanks. I had accidentally deleted Price from the indicators and added it back in. It added after all the MAs. I took out the MAs, leaving only the Price and it works fine now. Why does the order of the things on the display affect arrows?

@DanaF, I suppose that the "automatic" trade arrows are only applied to the first price series array (or an average of prices) that is plotted in the chart.

But to know for sure, you need to ask to @Tomasz.

Thanks for the help. It works fine now. Good to know it is order dependent.

This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.