Can't find GetDailyBar in WL5
Author: jimcrist
Creation Date: 12/2/2008 9:17 AM
profile picture

jimcrist

#1
I'm trying to get up to speed on WL5, but even my WL4 is rusty. I need the official EOD data so I can calculate moving averages, average volumes, etc. But I also need 15 minute bars for determining the entry signal. What happened to GetDailyBar in WL5??? Thanks...
profile picture

Eugene

#2
You're right, no Get*Bar functions in WL5 but they can be pretty easily coded. Welcome to our WL5 Wiki, Knowledge Base:

Intraday / Multi-Time Frame | GetIntradayBar and the similar functions
profile picture

jimcrist

#3
Thanks Eugene. I can't say I get it yet, but I'll keep studying the examples and do some experimenting. So, can I access the offical daily bars or is this just gonna roll all the 15 minute bars into a daily bar? What I really want is two different input streams.
profile picture

Eugene

#4
QUOTE:
So, can I access the offical daily bars or is this just gonna roll all the 15 minute bars into a daily bar?

SetScaleDaily (for example, as shown in the Get*Bar workaround) here compresses the original intraday series into daily. Anyway, Get*Bar should not help you retrieve the official EOD data close if by that you mean a separate daily data series. Am I getting it right?

QUOTE:
What I really want is two different input streams.

To reference a different (external) series, use GetExternalSymbol. In WL 5.3, there's going to be a new override method to specify a particular DataSet from which to grab the data from -- sort of the old school AllowSymbolSearch.
profile picture

jimcrist

#5
Thanks. Yes, I want to read daily bars and 15 minute bars. I should have mentioned I'm using Fidelity data. I guess I could use the .NET language to read the *.WL files directly, but I was hoping WL5 would help with that. Hopefully, that's what GetExternalSymbol will do...
profile picture

Eugene

#6
Wealth-Lab 5 file format is unpublished (and is undergoing a slight change as of ver. 5.3) but reading the *.WL files is currently possible too.

The 5.3 QuickRef will have this aspect covered, but the method is already present and can be called (in a Strategy or in a 3rd party app) -- Bars.LoadFromFile, which loads the Bars object from an existing file on disk.
profile picture

jimcrist

#7
I can't find any documentation on Bars.LoadFromFile. Is there any? What are the parameters? I'm using WL 5.1.75.0
profile picture

Cone

#8
Generally, undocumented methods are not supported, but we agreed that .LoadFromFile and .SaveToFile were useful and supportable, and they will be documented for next release. Here's a copy -

CODE:
Please log in to see this code.
profile picture

jimcrist

#9
I'm trying get this to work and can't. The Synchronize is throwing a runtime error: "Index was out of range. Must be non-negative and less than the size of the collection."

The A.WL daily file exists, but it's being updated by WL4. Is that a problem?
CODE:
Please log in to see this code.
profile picture

jimcrist

#10
I added a PrintDebug( bars.Count ) before the Synchronize and it's 0. So it's not finding the file or it's failing 'cuz it's in WL4 format?
profile picture

jimcrist

#11
I created a A.WL file using WL5 and got it to work. I have over 3 gig of WL4 data and I read the files directly using VB.NET. I wrote my own backtesting program 'cuz I couldn't read both daily and 15-min bars into WL4. I update 2714 daily files and 2714 15-min bar files. So, now I have to do double updates and try to transition to WL5? Ugh. How much longer will WL4 be supported?
profile picture

Eugene

#12
QUOTE:
I added a PrintDebug( bars.Count ) before the Synchronize and it's 0. So it's not finding the file or it's failing 'cuz it's in WL4 format?

That's right, the WL file format is different in WL5 and will change in 5.3 as well (the older files will still be read). The methods are intended to work with WL5-generated files.

I don't get the point, why do you need to read those WL4 files directly if there's a WL4 files provider? Nonetheless, in 5.3 I believe you will have the means to access intraday and daily Fidelity data of the same symbol in the WL4 format with the new GetExternalSymbol() overload and the already existing WL4 Files provider.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).