Symbol info/stats on a Pane
Author: ichechet
Creation Date: 10/20/2010 11:09 PM
profile picture

ichechet

#1
I want to see some symbol stats, not strategy stats. Is it possible to make it in WLD? I want to make it something like in optimizing.
profile picture

Eugene

#2
Please be specific and verbose. This is not clear enough.
profile picture

ichechet

#3
OK. Here is my scenario. I have a Symbol and time frame. I want to see a diagram which will show me som especific info about this Symbol, i.e. volatility graph. Of course I can code the strategy with idicator and see it on Graph. But I'd like to see all the results in one Pane. Is it possible?
profile picture

Eugene

#4
Sure it's possible - through a custom performance visualizer:

Wealth-Lab Version 6 (.NET) Development Guide > "Performance Visualizers | Download PDF"
Home - MS123 Visualizers Download Project Source Code (2010.07)
profile picture

ichechet

#5
OK, I think it's the right decision. Is it possible to pass there Bars object? I need there High and Low bar values. Is any visualization components available from WLD? Like the one from the Equity Curve?
profile picture

Eugene

#6
You should be able to pass a Bars object (or in fact almost any object) there by assigning it to the Position.Tag property. However note, that each Position already has a Bars object attached:

SystemPerformance.Results.Positions[] -> Position.Bars
profile picture

ichechet

#7
QUOTE:
SystemPerformance.Results.Positions[] -> Position.Bars


All the bars? Or only bars from position. I need all the bars regardless of position (it even can be nothing positions at all). I can get it all in strategy code, but it's WealthScript.Bars object. I can't see Bars object from IPerformanceVisualizer interface.

I see void CreateVisualization(WealthLab.SystemPerformance performance, WealthLab.IVisualizerHost visHost). I can store there SystemPerformance.Bars object, but is it all bars?
profile picture

Eugene

#8
QUOTE:
All the bars? Or only bars from position.

The Bars object associated with the Position. You can't "arbitrarily pass an object to a visualizer" - like I said, you're doing this by storing an object with the Position.Tag property and accessing it later.

To retrieve the collection of Bars objects that belongs to a portfolio backtest, loop through SystemPerformance.Results.Positions, accessing the Bars object of the current Position.
QUOTE:
I can't see Bars object from IPerformanceVisualizer interface.

Take a look at my 2nd link above. Check out the open source code, there's a dozen of examples how to work with Positions in CreateVisualization (the heart of a visualizer, sort of void Main() or Execute()).
profile picture

ichechet

#9
Am I right?

In strategy I have to put this code:

CODE:
Please log in to see this code.


In PV code in CreateVisualization(WealthLab.SystemPerformance, WealthLab.IVisualizerHost) I have to put this code:

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

Cone

#10
No. Eugene has instructed that each Position has a Bars object associated with it. In other words, you can access it using the Position object.

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

Eugene

#11
Just a small clarification for Igor:
CODE:
Please log in to see this code.
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).