'Daily TP / trailing

I use the folllowing code for daily loss control. Is there a way to control daily take profit and/or daily trailing tp/sl?

dailyloss=input.float(title=" Dailiy loss", defval=1.6, minval=0.1, step=0.1)
strategy.risk.max_intraday_loss(value=dailyloss, type=strategy.percent_of_equity)


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source