/*backtest
start: 2021-05-08 00:00:00
end: 2022-05-07 23:59:00
period: 4h
basePeriod: 15m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=4
study("T-Step LSMA",overlay=true)
length = input(100),sc = input(.5),ns = input(false,"No Smoothing")
//----
b = 0.,ls = 0.