Strategy: Buy on 55-day high, multiple positions, ATR stop
Author: Trader288
Creation Date: 11/23/2016 2:26 PM
profile picture

Trader288

#1
I'm trying to create my first trading strategy, using existing "rules" in Wealth Lab Pro and want to confirm that I'm doing it correctly. Here is what I'd like to build:
Trigger an alert for a long position when a security (say one of the Dow 30) hits a new 55-day high.
Use a stop loss on that positon of a 15-day 2X ATR.
Trigger another long position in the same security when it increases in price by 1 ATR.
Move the stop loss on all positions to 2 ATRs
Sell all positions if the price of the security hits a new 20-day low.
What are the rules and conditions needed to create this strategy. Thanks very much for your time. Trader288
profile picture

Eugene

#2
Welcome to the forums.

You probably won't be able to create this strategy using Rules as it goes beyond available conditions. Give this a try:
CODE:
Please log in to see this code.
profile picture

Trader288

#3
Thanks Eugene! Much appreciated.
profile picture

Trader288

#4
I noticed on another Forum post that you mentioned C+ for coding. Is that the best programming language for Wealth-lab. It seems for be the easiest to learn for someone with no coding experience - would you agree? Thanks
profile picture

Cone

#5
Not C+, but C#.

You can develop Wealth-Lab strategies in any .NET language, but the built-in editor/compiler is for C#.

Learning a programming language is mostly about its syntax. Although there are parts of every modern programming language that get esoteric, C# was invented for .NET and borrows some of the best features from other languages.
profile picture

Trader288

#6
Thanks!
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).