Hello Quantopian,
Question 1:
I would like to know if there is currently, or on the to-do list, a way to place moving stop-loss orders. Say I place an order with a stop at 10% below the order price, if the price goes up I would want that 10% to follow the price rise and lock in some gains. Maybe something to the effect of
order(Sid, n, stop_price=lambda price: .9*price if price > current_price else .9*current_price)
I don't know how feasible something like this would be, but it sure would be nice.
Question 2:
When using TA-Lib functions with minute data is the function basing the output on the last n minutes of data? For example is ta.EMA(time_period=30) returning the EMA of the last half hour? If so, is there another keyword arg for days, mins, etc. or do we need to always use mins and make conversions as necessary?
Thanks,
David