The "EMASkipPump" strategy is a basic trading strategy designed to avoid pump and dump market conditions. It uses a combination of Exponential Moving Averages (EMAs) and Bollinger Bands as indicators. Here are the important parts of the strategy:
EMAs: The strategy calculates three EMAs with different time periods: short-term (5), medium-term (12), and long-term (21).
These EMAs are used to analyze the trend of the price data.
Bollinger Bands: The strategy also calculates Bollinger Bands using the typical price and a window of 20.
The lower band, middle band, and upper band of the Bollinger Bands are used for further analysis. Buy Condition: The strategy identifies a buy opportunity when the following conditions are met:
Volume is less than the 20-day moving average of volume multiplied by 20. The closing price is below both the short-term and medium-term EMAs. The closing price is at the minimum value within the medium-term EMA window. The closing price is below or equal to the lower Bollinger Band. Sell Condition: The strategy identifies a sell opportunity when the following conditions are met:
The closing price is above both the short-term and medium-term EMAs. The closing price is at the maximum value within the medium-term EMA window. The closing price is above or equal to the upper Bollinger Band. The strategy has a minimal return on investment (ROI) of 0.1 (10%) and a stop loss of -0.05 (-5%). It operates on a 5-minute timeframe. The "populate_indicators" function calculates the EMAs, Bollinger Bands, and additional indicators such as the minimum and maximum values within the medium-term EMA window. The "populate_buy_trend" function identifies buy signals based on the specified conditions and sets the 'buy' column to 1 for those instances. The "populate_sell_trend" function identifies sell signals based on the specified conditions and sets the 'sell' column to 1 for those instances. Overall, the strategy aims to capture potential buying opportunities while avoiding pump and dump scenarios, using a combination of trend analysis and price volatility indicators.