question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

MACD is not consisten with TradeView

See original GitHub issue

the problem

when using the same params, macd gold cross is not consistent with what is TradeView

image image

the first column on the screenshot of the console output is the time I buy the stock (it should be the K line which generating macd gold cross ), but it is sometimes later or earlier than what is generated by the Stock.Indicator

the code:

List<MacdResult> macd = quotesList5m.GetMacd(5, 34, 5, CandlePart.OHLC4).ToList(); ........ bool buy = macd[i - 1].Histogram < 0 && macd[i].Histogram > 0

when the boll buy == true, I will buy stocks.

I use ES in this case, but you can use any stock to reproduce the issue.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
DaveSkendercommented, Apr 27, 2022
0reactions
DaveSkendercommented, Apr 28, 2022

Let me know if you still have unresolved issues that I can help resolve.

Read more comments on GitHub >

github_iconTop Results From Across the Web

MACD (Moving Average Convergence/Divergence)
MACD is an extremely popular indicator used in technical analysis. ... Simply put, divergence is when the MACD and actual price are not...
Read more >
Moving Average Convergence / Divergence (MACD)
MACD – What it is The Moving Average Convergence Divergence (MACD) is the momentum indicator that shows the relationship between two different moving...
Read more >
Moving Average Convergence / Divergence (MACD)
The Adaptive MACD indicator is an adaptive version of the popular Moving Average Convergence Divergence (MACD) oscillator, returning longer-term variations ...
Read more >
I can't find an indicator (Volume, MACD, Ichimoku or other)
Click the Indicators button in the top toolbar, start typing the name of the indicator and then click on the indicator on the...
Read more >
Better Than MACD! This POWERFUL TradingView Indicator ...
... financial, accounting, tax, legal, regulatory or similar advice, and it is not an endorsement of any provider, product or service.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found