Hello there,
I have a very simple screener that looks for stocks where the 20 day EMA crosses above the 200 SMA in the last three days. When I run the screener some stocks fit the criteria as you would expect but it also brings up other stocks that do not. They are generally close but do not comply exactly . I have put on the Screener and an example of three of the results. As you can see one is exactly as you would expect but the other two are not…. anyone have any ideas why this should be ? The Blue arrow indicator on the chart is also an indicator that says when the 20EMA crosses the 200 SMA so all the results should have this as a feature and as you can see they do not.
Hi! your code is fine.
The difference comes from the price data, not from the code. ProScreener always works with dividend-adjusted prices. You can see it at the bottom of the scan selection panel in your first screenshot: “Prices are adjusted to dividends”. Your charts, on the other hand, are not adjusted.