NexusFi: Find Your Edge


Home Menu

 





Wealthlabpro to EasyLanguage


Discussion in EasyLanguage Programming

Updated
    1. trending_up 4,040 views
    2. thumb_up 1 thanks given
    3. group 2 followers
    1. forum 2 posts
    2. attach_file 1 attachments




 
Search this Thread

Wealthlabpro to EasyLanguage

  #1 (permalink)
rajeshu
Austin, TX, USA
 
Posts: 3 since Jun 2020
Thanks Given: 1
Thanks Received: 1

Hi,

I have a strategy which I backtested in wealthlabpro and got acceptable results. I tried to convert the sell order code to easy language but was not able to figure out the exact piece of easylangauge code.

This is the sell order wealthlabpro code I have:
if (!SellAtLimit(bar + 1, Position.AllPositions, LastPosition.EntryPrice + 0.05, "Profit target5"))
{
attached full code
}

Explanation of SellAtLimit

bool SellAtLimit(int bar, Position pos, double limitPrice, string signalName);
bool SellAtLimit(int bar, Position pos, double limitPrice);

Sells the Position specified in the pos parameter at the specified bar, using a limit order at the specified limitPrice. SellAtLimit returns a bool value indicating whether the price reached the limitPrice or above, and the Position was sold. SellAtLimit will also return false if the bar specified is greater than the number of bars on the chart. In this case, a sell Alert will be generated instead.

In EasyLanguage (EL) I was able to generate the sell order as:
Sell ("Profit Target5") all shares next bar at (Entryprice + 0.04) Limit;

But cant conditionally move to next logic (as in wealthlabpro) if current order is not filled.

Really appreciate any help on this!

Attached Files
Elite Membership required to download: sell.txt
Reply With Quote

Can you help answer these questions
from other members on NexusFi?
About a successful futures trader who didnt know anythin …
Psychology and Money Management
Trade idea based off three indicators.
Traders Hideout
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
Better Renko Gaps
The Elite Circle
Quantum physics & Trading dynamics
The Elite Circle
 
  #2 (permalink)
TradingGuy
Connecticut
 
Posts: 15 since Jan 2011
Thanks Given: 1
Thanks Received: 8

Rather than use the Sell order as the test as with WLP, set up test criteria in EL and submit the order or create an alert.

Use tick processing and check close against the desired criteria, then use conditional logic to decide on action.

Reply With Quote
Thanked by:
  #3 (permalink)
rajeshu
Austin, TX, USA
 
Posts: 3 since Jun 2020
Thanks Given: 1
Thanks Received: 1



TradingGuy View Post
Rather than use the Sell order as the test as with WLP, set up test criteria in EL and submit the order or create an alert.

Use tick processing and check close against the desired criteria, then use conditional logic to decide on action.

Makes sense, being new to EL can you please let me know how to enable tick processing OR I need to change the code to look into ticks?

Reply With Quote




Last Updated on June 11, 2020


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts