William %R is a very popular indicator and is extensively used for technical analysis in the financial markets.
Those who use Amibroker use this indicator often. However it may happen accidentally that the AFL used for William %R is deleted from the software. This brings in a lot of trouble for those who might not be very much familiar with the coding process.
To overcome this problem I am posting the AFL for the indicator here which can be copied from here then applied in the Amibroker software through the Formula Editor .
=============================Copy The Code From Below======================
_SECTION_BEGIN("William's % R");
function PercentR( periods )
{
return -100 * ( HHV( H, periods ) - C )/( HHV( H, periods ) - LLV( L, periods ) );
}
Plot( PercentR( Param("Periods", 14, 2, 100 ) ),
_DEFAULT_NAME(),
ParamColor("Color", ColorCycle ) );
_SECTION_END();
==============================The End====================================
Those who use Amibroker use this indicator often. However it may happen accidentally that the AFL used for William %R is deleted from the software. This brings in a lot of trouble for those who might not be very much familiar with the coding process.
To overcome this problem I am posting the AFL for the indicator here which can be copied from here then applied in the Amibroker software through the Formula Editor .
=============================Copy The Code From Below======================
_SECTION_BEGIN("William's % R");
function PercentR( periods )
{
return -100 * ( HHV( H, periods ) - C )/( HHV( H, periods ) - LLV( L, periods ) );
}
Plot( PercentR( Param("Periods", 14, 2, 100 ) ),
_DEFAULT_NAME(),
ParamColor("Color", ColorCycle ) );
_SECTION_END();
==============================The End====================================
Thanks so much!!!
ReplyDelete