First time writing a question here!
I'm creating a simple bot to trade with stock. It uses indicators such as Moving Averages or Bollinger bands to evaluate the price of the stock and decide whether to buy, hold or sell depending on the values of these indicators. This evaluation is made periodically (every 4 hours let's say).
When it's time for the bot to evaluate the position, he requests the value of the stock at that precise moment (current value) and adds this value to the indicator.
Until here everything is alright. However, I am wondering what is more representative to correctly compute the indicator. For the past values, should I use :
- The current values that I used in previous periods
- The mean values from past candlesticks
I hope I'm clear enough.
Thanks for your advice!
UPDATE
I feel i didn't explain myself well enough. at every period, the bot checks the current price of the stock (1. in question above and yellow circle in the graph).
On the other hand, there are the candlesticks (in green and orange) which have their mean value (2. in question above and blue circle in the graph).
I'm not sure whether to use the means of the candlesticks (in blue) to create the indicators or the current value (in yellow).
I hope I made myself clearer.