PerformanceEngine.cs
Author: sedelstein
Creation Date: 5/17/2013 5:39 PM
profile picture

sedelstein

#1
In the old MS123 Visualizers library there was a file called PerformanceEngine.cs
Has this moved or is it available somewhere else. I know that the whole RunDonor strategy had a breaking change a while back.

Thx
profile picture

Eugene

#2
The internal and unsupported PerformanceEngine class is still there in the WealthLab.Visualizers.MS123 namespace, rewritten from scratch and delivering the performance metrics to all members of MS123 Visualizers. However, it has never included "runDonor" -- that's the prerogative of Community Components. As it's not entirely clear to me, could you clarify what you're after?
profile picture

sedelstein

#3
I found the code. what I'm after is the statistics generated by running a strategy on a single symbol and outputting those values to a file.
I want to run many symbols and then rank order the symbols based on some selection criteria. I had this running before but not since the "breaking change" described here http://www.wealth-lab.com/Forum/Posts/Access-Wealth-Lab-Score-from-Strategy-32433

profile picture

sedelstein

#4
I am getting messages about Community Components is "obsolete" despite having updated all extensions
profile picture

Eugene

#5
QUOTE:
I am getting messages about Community Components is "obsolete" despite having updated all extensions


This is a heads-up, and it's there on purpose. With the advent of extension methods - a C# 3.0 feature - I consider the majority of pre-2013.05 legacy syntax "obsolete". The Wiki examples have been updated to reflect the new usage patterns, but everyone can continue running their legacy code as nothing happened. Through wrappers to new extension methods, the old syntax stays supported forever (exception: new additions will never be backported). Since C.Components is a utility library, the need to create classes has been minimized: we're using static classes/methods wherever possible, and the new extension method syntax makes it even easier, more comfortable and terse.

QUOTE:
I had this running before but not since the "breaking change" described here


Starting from v2012.11, MS123 Visualizers include an own 'Utility' class - perhaps this is the source of confusion with 'Community.Components.Utility' that you were using. Posts #16 and #17 by your link contain everything one needs to know to adjust their code to the breaking change in the unsupported internal class.
profile picture

sedelstein

#6
Okay, perhaps you can help me out one more time. The following code works just fine

CODE:
Please log in to see this code.



If I try to replace the last line with
CODE:
Please log in to see this code.


which used to work. I get the message about the Utility is obsolete. I'm having difficulty figuring out what's going wrong. I seem to be referencing the right things as per your post above.

Appreciate the help. It is rather important to me
profile picture

Eugene

#7
Current revision of the unsupported internal PerformanceEngine class has no public variable "win_pct". Are you looking for pe.PctWinners?
profile picture

sedelstein

#8
Yes! as well as others. I believe the AvgProftWinPct has changed as well

I'd like to know all the public properties. I thought I had found them but it seems I am looking at the wrong places.
Can you point me toward the zip file to download.

Many thanks
profile picture

sedelstein

#9
Version 2013.01 seems to be current.
The zip file version is 2012.07 on the wiki site

I use the built in c# editor in WL. Often I can see the properties for example, in the code above, if I write x = sp. (after the dot is typed, the available methods and properties appear. Not so with pe "dot"

Am I doing something wrong
profile picture

Eugene

#10
The demo solution is stuck forever at 2012.07 after the total rewrite of the library. It was decided that the old version is perfectly enough for the demo purposes and therefore will not be updated.

At the risk of repeating, the PerformanceEngine class is unsupported and internal. So you're completely on your own with it. No public and/or other properties will ever be documented. Feel free to explore its properties using Visual Studio's Object Browser and similar tools. Please look for any assistance on Visual Studio forums and by studying your Visual Studio manual.

Good luck with your venture, and I really appreciate your understanding that you're using an undocumented method with all that that implies.
profile picture

mjj3

#11
Eugene,
You mentioned above that the wiki was updated with the new supported usage patterns. Could you point me in the right direction in wiki to view these as there is no time stamp with regard to updates in the wiki. Thanks ahead of time for your help.
profile picture

Eugene

#12
Just sort by modification date, like this:

Pages of the Category Community Components

Those updated on 2013/05/11 contain examples using both C# extension methods and traditional syntax.
profile picture

mjj3

#13
Thanks Eugene.
profile picture

sedelstein

#14
Hello Eugene

In the old method http://www2.wealth-lab.com/WL5WIKI/kbInteractingWithPortfolioEquity.ashx there was some code

CODE:
Please log in to see this code.


that no longer works

Is there an updated way to do this. I've got 99% of what I need but it runs too long on large datasets. This was the previous workaround.

Thanks
profile picture

Eugene

#15
A slowdown on "trading the equity curve" using that code is expected as per "Notes and Limitations". There's nothing to fix because the KB article code is not broken.
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).