Hi,
I've read various wiki pages and the pdf guide and they state the market scanner can only work on one resolution (which I'm equating to timeframe, i.e. 5 mins, 1 day etc...) per instrument (so per line on the market scanner). Is it possible to write an indicator which accesses data from multiple time frames and add it to the market scanner?
Context as an exmaple is to create an indicator that takes the volume from the last 20 day periods (so 20 bars) and averages it but the resolution of the line on the market scanner would be 5 mins. I've seen various posts which contradict each other at times.
If absolutely necessary this could include more complex programming, i.e. accessing the data through a class which reads from an external file but ideally it would be as simple as possible and would use a second data series.
Thanks
Market Scanner - Multi Timeframe in Indicator
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2957 times
Re: Market Scanner - Multi Timeframe in Indicator
Hello tmfdouglas,
There are multiple ways to achieve this goal:
There are multiple ways to achieve this goal:
- CustomInstrument class - easily access the data series loaded by the DataLoader with the bars tied to the bars of the main data series based on time: Example here;
- Use the DataLoader to obtain data, build required resolution, create a study that can be calculated on the raw array of data from DataLoader;
- Transfer data values from a chart into the scanner using Global Storage/Global Variables: MultiCharts .NET FAQ #10.
Re: Market Scanner - Multi Timeframe in Indicator
Hi, this is precisely what I have been trying to achieve. I'm using the CustomInstrument object but when adding the indicator to the scanner window, it doesn't seem to match the indicator value on the chart with the same resolution. What am I doing wrong?
I also get a bunch of Application Error popups when recompiling and removing/adding that indicator to the scanner.
I also get a bunch of Application Error popups when recompiling and removing/adding that indicator to the scanner.
- Attachments
-
- 2016-11-04_13-08-27.png
- (17.99 KiB) Downloaded 1084 times
-
- _Test_Watchlist.pln
- (1.89 KiB) Downloaded 382 times