AFL code wizard does not provide [cross over]?

AFL code wizard provides [is equal to, is less than, is greater than].

There seems no [cross over] can be choose.

Is there any answer?

Thank you!

Greater than is a STATE version of Cross above (impulse form).
Less than is a STATE version of Cross below (impulse form).

More on this: http://blueowlpress.com/system-development/impulse-versus-state-signals/

From backtester point of view they are functionally equivalent as backtester automatically removes redundant signals in regular mode effectively converting from state to impulse form.
http://www.amibroker.com/guide/h_portfolio.html

The other reason is that you can not really reliably combine two or more conditions using impulse (cross) form as they would only work when all signals happening on exactly same bar which is very rare. For beginners it would lead to confusion and questions like "why my AND does not work". So this is avoided by having simple > and < comparisons.

2 Likes

I agree your view of point.
but my original purpose for this article is:

there is a function named 'Cross' in AFL,
and there are functions like 'Value of', 'MA', 'EMA', 'DEMA', 'TEMA' ...
in the AFL wizard, but seems no 'Cross' function in the AFL wizard.
AFL_wizard_Edit_Rule

I think the key point you said is:

Having simple > and < comparisons
to avoid begnners to confuse about the meaning of 'Cross'.

Because the 'Cross' combines greater than (or less than) previous bar
and less than (or greater than) this bar.

@alexlin - I already explained it detail EARLIER IN THIS THREAD.

Did you read that?

The thing is that beginners usually don't understand the difference between signal and state forms. Comparisons (>, <) generate state form, while crosses generate signal form. Once you ever want to combine more than one condition in signal/impulse form using AND/OR you are likely to have synchronization problem because AND would only work if both conditions (like cross) occurred PRECISELY at the same bar, which in most cases does not happen. So, state form is preferred for trading rules consisting of more than one condition.

2 Likes