@DazN, I briefly looked at the author's site.
On the FAQ page he posted a TC2000 formula. AFAIU, it should be:
// TC 2000 - code - From: https://qullamaggie.com/faq/
// It’s the average daily range in % over the past 20 sessions.
// 100*((H0/L0+H1/L1+H2/L2+H3/L3+H4/L4+H5/L5+H6/L6+H7/L7+H8/L8+H9/L9+H10/L10+
// H11/L11+H12/L12+H13/L13+H14/L14+H15/L15+H16/L16+H17/L17+H18/L18+H19/L19)/20 -1)
period = 20;
ADR = 100 * ( MA( High / Low, period ) - 1 );
Plot( ADR, StrFormat("ADR(%g)", period), colorOrange );
I was also looking for this ADR formula and I wanted it to display on the top of the chart as text for the current value, so I adapted the code by beppe. Maybe someone else wants to use it too.
_SECTION_BEGIN("ADR");
// adapted to AFL by beppe, https://forum.amibroker.com/t/qullamaggie-adr-formula-for-ab/35933/3
// modified by RioL for userdefined parameters, to be able to use the style "hidden" => current ADR will only be shown in the top of the chart
//////////////////////////////////////////////////////////
// TC 2000 - code - From: https://qullamaggie.com/faq/
// It’s the average daily range in % over the past 20 sessions.
// 100*((H0/L0+H1/L1+H2/L2+H3/L3+H4/L4+H5/L5+H6/L6+H7/L7+H8/L8+H9/L9+H10/L10+
// H11/L11+H12/L12+H13/L13+H14/L14+H15/L15+H16/L16+H17/L17+H18/L18+H19/L19)/20 -1)
Periods = Param("Periods", 20, 2, 300, 1, 10 );
ADR = 100 * ( MA( High / Low, Periods ) - 1 );
Plot( ADR, StrFormat("ADR(%g)", Periods), ParamColor( "Color", colorCycle ), ParamStyle("Style") );
_SECTION_END();