Please note that this should really be used in conjunction with a higher timeframe "Anchor" chart with a fast and a slow so setups and positions should should correspond to the trend of the higher timeframe chart. This was designed for a 5 minute timeframe and a 60 minute anchor chart.
In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.