Thanks Cone! I'm just getting started with WL. How to turn a strategy into a screener?
Rename
Assuming that you're using Block Strategies, here are the 3 steps:
1. Put the screener conditions in a Buy or Short logic block
2. Click "Open as a C# Coded Strategy"
3. Find the Execute() method and add this statement at the top -
When you're done, the Execute method will start something like this:
Save your screener and run it on any DataSet. The "Signals" are the result of your screen.
1. Put the screener conditions in a Buy or Short logic block
2. Click "Open as a C# Coded Strategy"
3. Find the Execute() method and add this statement at the top -
CODE:
if (idx < bars.Count - 1) return;
When you're done, the Execute method will start something like this:
CODE:
public override void Execute(BarHistory bars, int idx) { if (idx < bars.Count - 1) return; // added this to make it a screener int index = idx; Position foundPosition0 = FindOpenPosition(0); bool condition0;
Save your screener and run it on any DataSet. The "Signals" are the result of your screen.
Your Response
Post
Edit Post
Login is required