EURUSD MACD 1 min Long OnlyThis MACD indicator uses two lines for long and sell long. It also uses a MACD indicator line with a historian. When the MACD historian crosses over the buy line, a long signal is executed. When the MACD historian crosses over the sell line, a close entry is signal is executed. There is a also a built in stop loss and you can adjust the buy and sell lines accordingly.
This does not repaint and I use it for autoview with an alert to autotrade this strategy.
Zbieżność/Rozbieżność Średnich Ruchomych (MACD)
MACD - EURUSD - 1min Long OnlyMACD strategy with a specified level the MACD and signal line must be under. Once the two lines cross under the specified level, a long entry is executed. When the MACD line crosses over the historian, the close entry will be executed. This strategy is designed around the high probability of a reversal in an under-bought trend.
Volatile Stocks - Simple Strategy w/Profit and StopThis strategy is based off of a script I wrote for another highly volatile asset, cryptocurrencies. It prints BUY and SELL signals based off of inputs that you can specify. I used this script as a time saver. If there is no signal on the chart, I'm less interested in analyzing it.
BUY SIGNALS
Bullish EMA Cross
Positive MACD Cross
Single-candle gains
SELL SIGNALS
Profit %
Stop Loss %
Naturally, I don't trade based off of the BUY and SELL signals alone, but it does help me identify the most important charts to look at.
Simple Alt Coin Strategy - EMA and MACD w/Profit and StopThis script prints BUY and SELL signals based on settings you input. I use it to save time while scrolling through charts deciding what alts I want to look at.
BUY SIGNALS
Positive EMA Crossover
Positive MACD Crossover
Single Candle Gains
SELL SIGNALS
Profit Capture
Stop Loss
I don't trade based just on the BUY or SELL from this strategy, but I have found that these indicators do very well well looking at the large cap alt coins. It backtests well.
Default Settings EMA 5/12/50, MACD 9/12/26, Single Candle Gain 10%, Stop 10%, Profit Capture 45%
MACD/EMA Long StrategyThis incredibly simple strategy uses a combination of the 20 EMA and bullish/bearish MACD crosses as a low risk method of getting in and out of markets.
Depending on whether the market is above or below the 200 SMA, the script determines if the market is in bullish or bearish territory. Above the 200 SMA, the script will ignore the 20 EMA as a buy condition and buy solely on the confirmation of a bullish MACD cross upon the close of a candle. In this bullish market, the script will only enable the sell condition if both the MACD is bearish AND a close below the 20 EMA occurs. This is to reduce the chances of the script selling prematurely in the event of a bearish MACD cross, if the market is still in overall bullish territory.
When the market is below the 200 SMA, the confirmation occurs in the opposite direction. The buy condition will only be met if both the MACD is bullish AND a close above the 20 EMA occurs. However, the sell condition ignores the 20 EMA and will sell solely on the confirmation of a bearish MACD cross upon the close of the candle.
This strategy can be used in both bullish and bearish markets. This conservative strategy will slightly underperform in a bull market, with the sell condition occasionally being met and then potentially buying back higher. However, it will successfully get you out of a turning market and automatically switch into a more 'risk-off' mentality during a bear market. This strategy is not recommended for sideways markets, as trading around the 20 EMA coupled with a relatively flat MACD profile can cause the strategy to buy the peaks and sell troughs easily.
MACD_Long_OnlyI created this indicator to calculate the gains that can be made purely by going long on the market. For exchanges without the ability to short, the standard MACD strategy is unable to accurately calculate the profit/loss from entering and exiting a position, as it includes profit/loss from actively shorting the market, which may either not be possible, or be undesirable for a specific asset.
Multiple MACD RSI simple strategySimple strategy script I've had for a while but looks like I never published.
Although it is one of my most simple it seems to have the best profitability. It is pretty rough though. the Stoch RSI has only a little weight to the trade trigger. I'll refine it more over time or you can by all means. Basically the Stoch RSI current K line has to be OVER 40 to trigger a SELL. It has no effect on buy side.
The triggers are roughly as follows:
Year - since so many assets have gone 2x, 3x, 10x+ since 2013 having a strategy that earns a 500% return from 2013 to now isn't that good if buy-and-holding would have got you 800%. This eliminates some of that noise and makes it a little easier to quickly gauge success. So buy/sell trigger need a value of greater or equal to 2018 (default)
MACD 1 - First MACD (short) needs to indicate greater than 0 to buy or less than 0 to sell.
MACD 2 - Same as MACD1 but for second MACD set (long)
Uptrend - Latest close + high divided by last periods close + high needs to be grater than 1. So if latest is 34.30 close and 34.60 high and previous interval is 34.80 close and 34.82 high, that is 0.99 and will not trigger a buy trade.
Downtrend - Same thing but close + low and less than 1.
This script/strategy is pretty rough but if there is interest I'll polish it more since it is a pretty solid but simple strategy for most assets.
Gold trading strategy with trend follow and TDOW conceptMy strategy uses a combination of three indicators MACD Stochastic RSI.
The Idea is to buy when ( MACD > Signal and RSI > 50 and Stochastic > 50) occures at the same time
This strategy works well on stocks and cryptos especially during market breaking up after consolidation
The best results are on Daily charts , so its NOT a scalping strategy. But it can work also on 1H charts.
The strategy does not have any stops and profit targets, so we can take all the market can give us at the moment.
The exit point only when MACD goes under Signal
In addition I've decided to add a stop loss and "Trading day of week" concept
So the results are much more stable and we get more profit !
So, use it, trade it.
If it will help you to imprive your trading results, please donate me
BTC: 12kd1F8buWisUBdq27BBwRkUvzW7Ey3og5
Stochastic & MACD Strategy Ver 1.0This strategy is inspired by ChartArt and jasonluk28.
The following input changes from the initial ChartArt version to achieve higher stability and profit:
Fast MA Len:11
Slow MA len: 24
Stoch Len: 20
No difference is found in minor changes (+-10) lv. of overbought/oversold
It works above 40% winning rate in Heng Heng Index, Shanghai Composite, Dow Jones Industrial Averge, S&P 500 NASDAQ, VT (World Total Market) and in 15 mins chart
Profit: above ~10 to 30% in less than 1year backtest for most major indice of China and US and ~62% in Heng Seng Index (Hong Kong) & 40.5% in SZSE Composite (Shen Zhen)
P.S. Profit: 700 (Tencent) +150.5%, 939 (CCB) +66.5%, 1299 (AIA) +45%, 2628 (CLIC) +41%, 1 (CK Hutchison) +31%
NFLX +82.5%, BABA +55.5%, AMZN +44%, GOOG +38%, MCD +24.5%
However, Loss in FB -19% , AMD -38.5%
Not suitable for stocks with great influences in News or Events ???
Ergotic MACD Strategy [forked from HPotter]Ergotic MACD Strategy forked from HPotter
In addition to this fine script you will find some additional features:
- Backtester
- Alerts
- Filters: RSI, MFI, Price trend
- Trailing Stop Loss
- Other minor adjustments
MACD+CCI Strategya simple strategy based on Joseph Nemeth MACD+CCI strategy
Reference reading: sites.google.com
EMA50Diff & MACD StrategyOne of my attempts to create a strategy for BTC.
Its a combination of EMA50Diff (the difference between spot and EMA50) and MACD.
Buy signal if (EMA50Diff) < -(EMADiffThreshold),
(MACD bearish crossunder),
(MACD) < -(MACDThreshold),
(EMA50Diff) > (EMA50Diff 1 candle ago),
(EMA50Diff 1 candle ago) < (EMA50Diff 2 candles ago)
Sell signal if (EMA50Diff) > (EMADiffThreshold),
(MACD bullish crossover),
(MACD) > (MACDThreshold),
(EMA50Diff) < (EMA50Diff 1 candle ago),
(EMA50Diff 1 candle ago) > (EMA50Diff 2 candles ago)
Exit either when target or stoploss get reached.
Initial capital is set to 100k and its currently going all-in on every trade but im looking for a better way to handle position sizes already..
Also i included slippage of 30 ticks and exchange commission of 0.15% (e.g. 2x BitMEX market taker fee)
Works best on 15m on bitfinex, bitstamp and gdax and i'm still trying to optimize it for bitmex too, will update when i got there..
Riz Coloured MACDThis is a souped up common or garden MACD . The Histogram is coloured giving a clear visual representation of where we are UpTicking or DownTicking on the Histogram to help support trading decisions.
When colour changes from pink to green market is bullish , and visa versa.
Very useful as a supporting indicator to confirm other strategies, or even as a standalone strategy to some extent.
Alerts are enabled by converting script from a Strategy to a Study, see comments in code.
SB_CM_MacD_Ult_MTFThis strategy places the order based on the MACD signal.
Original Indicator: MacD Custom Indicator-Multiple Time Frame+All Available Options! by ChrisMoody
Link to the Indicator:
If your risk appetite is high you can replace the first statement with the below statement:
strategy(title="SB_CM_MacD_Ult_MTF", shorttitle="SB_CM_MacD_Ult_MTF", default_qty_type = strategy.percent_of_equity, default_qty_value = 100, pyramiding = 5)
You can check for repainting. Did not check for that.
Message if you think of any modifications/ enhancements/ any opportunities. :)
Donations/Tips... :) -
BTC: 1BjswGcRR6c23pka7qh5t5k56j46cuyyy2
ETH: 0x64fed71c9d6c931639c7ba4671aeb6b05e6b3781
LTC: LKT2ykQ8QSzzfTDB6Tnsf12xwYPjgq95h4
SB_Elder Impulse SystemThe strategy is based on LazyBear's Elder Impulse System
Strategy(in layman terms):
Long: When the green bar in the Elder Impulse System's indicator shows up
Short: When the red bar in the Elder Impulse System's indicator shows up
Close trade/Profit booking: When the blue bar in the Elder Impulse System's indicator shows up
Original Idea:
Message in the script if you think of any modifications/ enhancements.
Donations/Tips... :) -
BTC: 1BjswGcRR6c23pka7qh5t5k56j46cuyyy2
ETH: 0x64fed71c9d6c931639c7ba4671aeb6b05e6b3781
LTC: LKT2ykQ8QSzzfTDB6Tnsf12xwYPjgq95h4
LFH/ Long positions using MACD histogram, long EMA and short EMADisclaimer: I'm a noob.
Hey there!
I'm trying to implement a script which enter market long position when long EMA crossover short EMA and MACD histogram is positive and histogram at T time is lesser than histogram at T-1.
And when short EMA crossover long EMA, plus MACD histogram is negative and histogram at T is greater than histogram at T-1, I want the script to exit market long position.
Now, I have something pretty close to what I am looking for. What I am missing and can't figure out yet is:
How to moderate entries, ie. I would like it to enter positions when trends are really interesting not just every time the conditions are fulfilled (same for exits) as there is way too much positions
I need to find a way to exit appropriated positions.
Combining Exponential And Volume Weighting Backtest The related article is copyrighted material from Stocks & Commodities 2009 Oct
You can change long to short in the Input Settings
WARNING:
- For purpose educate only
- This script to change bars colors.
Ichimoku Kinko Hyo + HULL-MA_X + MacDThe Ichimoku Kinko Hyo system includes five kinds of signal, of which this strategy uses the most recent of ones i.e. Tenkan Sen / Kijun Sen Cross and price crosses the Kijun Sen. As the Chikou Span, Senkou Span A and Senkou Span B are shifted into the past/future, the trigger signals will be only be used for visual confirmation and not part of the strategy.
The Tenkan Sen, also known as the Turning or Conversion line, is a moving average of the highest high and lowest low over the last 9 periods in this strategy.
The Kijun Sen, also known as the Standard or Base line, is a moving average of the highest high and lowest low over the last 24 periods in this strategy.
The Chikou Span, also known as the Lagging line, is the closing price plotted 24 periods behind in this strategy.
The Senkou Span A, also known as the 1st leading line, is a moving average of the Tenkan Sen and Kijun Sen and is plotted 24 periods ahead in this strategy.
The Senkou Span B, also known as the 2nd leading line, is a moving average of the highest high and lowest low over the last 51 trading days is plotted 24 periods ahead in this strategy.
Moving average convergence divergence (MaCD) is a trend-following momentum indicator that shows the relationship between two moving averages of prices. The MaCD is calculated in this strategy by subtracting the 24-day exponential moving average (EMA) from the 12-day EMA. A nine-day EMA of the MACD, called the "signal line", aMaCD in this case, is then plotted on top of the MaCD. In this strategy, MaCD/ aMaCD Cross is functioning as a trigger for buy and sell signals.
As with most technical analysis methods, Ichimoku is likely to produce frequent conflicting signals in non-trending markets, So in addition to Ichimoku Kinko Hyo, the Hull MA is popular amongst some day traders, as the indicator which in combination with MaCD attempts to give an accurate signal by eliminating lags and improving the smoothness of the line.
Alan Hull, developed this moving average indicator and hence it’s called the Hull MA.
Now, let’s dissect how the Hull moving average is calculated.
The Hull MA involves the weighted moving average (WMA) in its calculation.
First, calculate the WMA with period (n / 2) and multiply this by 2. Remember ‘n’ is the time period configurable based on the trader’s requirement. The default setting is 12 periods in this strategy, fast Hull MA crossing slow Hull MA will generate a circle on charts.
Second, calculate the WMA for period “n” and subtract if from the first step. Thirdly, calculate the weighted moving average with period sqrt (n) using the data from the second step. You can take a look at the below formula:
Hull MA= WMA (2*WMA (n/2) − WMA (n)), sqrt (n))
The Hull MA Cross in combination with Tenkan Sen / Kijun Sen Cross and MaCD tries to give an accurate signal by eliminating lags and improve the smoothness of price activity. Please note that price trends can and do change often, so your readings of the charts and this trading system should be probabilistic, rather than predictive.
MACD Crossover Backtest MACD – Moving Average Convergence Divergence. The MACD is calculated
by subtracting a 26-day moving average of a security's price from a
12-day moving average of its price. The result is an indicator that
oscillates above and below zero. When the MACD is above zero, it means
the 12-day moving average is higher than the 26-day moving average.
This is bullish as it shows that current expectations (i.e., the 12-day
moving average) are more bullish than previous expectations (i.e., the
26-day average). This implies a bullish, or upward, shift in the supply/demand
lines. When the MACD falls below zero, it means that the 12-day moving average
is less than the 26-day moving average, implying a bearish shift in the
supply/demand lines.
A 9-day moving average of the MACD (not of the security's price) is usually
plotted on top of the MACD indicator. This line is referred to as the "signal"
line. The signal line anticipates the convergence of the two moving averages
(i.e., the movement of the MACD toward the zero line).
Let's consider the rational behind this technique. The MACD is the difference
between two moving averages of price. When the shorter-term moving average rises
above the longer-term moving average (i.e., the MACD rises above zero), it means
that investor expectations are becoming more bullish (i.e., there has been an
upward shift in the supply/demand lines). By plotting a 9-day moving average of
the MACD, we can see the changing of expectations (i.e., the shifting of the
supply/demand lines) as they occur.
You can change long to short in the Input Settings
WARNING:
- For purpose educate only
- This script to change bars colors.