NexusFi: Find Your Edge


Home Menu

 





IntrabarOrderGeneration


Discussion in EasyLanguage Programming

Updated
    1. trending_up 3,004 views
    2. thumb_up 1 thanks given
    3. group 2 followers
    1. forum 6 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
AhmedF
north bergen
 
Posts: 13 since Feb 2017
Thanks Given: 3
Thanks Received: 1

how do i get [IntrabarOrderGeneration = True] to work on one section of the code and not affect the entries and exits.

What i am trying to accomplish is have money management strategies work one tick later rather than one bar later.


Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Warsh Confirmed 54-45 on PPI Day -- 97% Say He Holds in …
Prediction Markets & Event Contracts
Day 96 Missiles Hit Kuwait and Bahrain: June 15 Peace at …
Prediction Markets & Event Contracts
Peace Deal Forward Curve: May 22%, June 51%, December 81 …
Prediction Markets & Event Contracts
Roland Garros Final Day: $3M on Zverev at 80.5% -- Leban …
Prediction Markets & Event Contracts
Iran Update May 8: Still Reviewing MOU, Demands Reparati …
Traders Hideout
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
NexusFi site changelog and issues/problem reporting
15 thanks
Darmok and Jalad at Tanagra
3 thanks
Big Mike in Ecuador
1 thanks
30 Sessions
1 thanks
  #3 (permalink)
 ABCTG   is a Vendor
 
Posts: 2,448 since Apr 2013
Thanks Given: 494
Thanks Received: 1,643


AhmedF,

the IntrabarOrderGeneration attribute will affect the whole code. You can look into the reserved word BarStatus to execute certain parts of your code at the end of the bar only for example.

Regards,

ABCTG


Follow me on X Reply With Quote
Thanked by:
  #4 (permalink)
AhmedF
north bergen
 
Posts: 13 since Feb 2017
Thanks Given: 3
Thanks Received: 1

OK, thanks,

An other question can you tell me if something is wrong with the following section of the code for some reason it is not functioning correctly

if (data2var99 crosses over 0) and (data2var10> 0)
then begin
VVSUP = true;
VVSDN = false;
end;
if (data2var99 crosses under 0) and (data2var10> 0)
then begin
VVSUP = false;
VVSDN = true;
end;

if VVSUP then begin
if indicator crosses over 0 then buy next bar at market;
if marketposition = 1 and indicator crosses under 0 then sell next bar at market;
end;

if VVSDN then begin
if indicator crosses under 0 then sellshort next bar at market;
if marketposition =-1 and indicator crosses over 0 then buytocover next bar at market;
end;

else

if (data2var98 crosses over 0) and (data2var10< 0)
then begin
WWSUP = true;
WWSDN = false;
end;
if (data2var98 crosses under 0) and (data2var10< 0)
then begin
VVSUP = false;
VVSDN = true;
end;

if WWSUP then begin
if indicator crosses over 0 then buy next bar at market;
if marketposition = 1 and indicator crosses under 0 then sell next bar at market;
end;

if WWSDN then begin
if indicator crosses under 0 then sellshort next bar at market;
if marketposition =-1 and indicator crosses over 0 then buytocover next bar at market;
end;
end;








ABCTG View Post
AhmedF,

the IntrabarOrderGeneration attribute will affect the whole code. You can look into the reserved word BarStatus to execute certain parts of your code at the end of the bar only for example.

Regards,

ABCTG


Reply With Quote
  #5 (permalink)
 ABCTG   is a Vendor
 
Posts: 2,448 since Apr 2013
Thanks Given: 494
Thanks Received: 1,643

AhmedF,

what does the code do and what exactly do you want it to do instead?

Regards,

ABCTG


Follow me on X Reply With Quote
  #6 (permalink)
AhmedF
north bergen
 
Posts: 13 since Feb 2017
Thanks Given: 3
Thanks Received: 1

it only executes trades on data in both directions and ignores data2

what i want it to do is as long as data2 is up i want to trade up only nothing else at all.
and when its down simply trade down.

and when data2indicator2 <0 i want it to trade in both directions


ABCTG View Post
AhmedF,

what does the code do and what exactly do you want it to do instead?

Regards,

ABCTG


Reply With Quote
  #7 (permalink)
 ABCTG   is a Vendor
 
Posts: 2,448 since Apr 2013
Thanks Given: 494
Thanks Received: 1,643

AhmedF,

I would suggest to use the "print" reserved word - the helpfile and wiki will show you how to use it -
to print the values of your code when a signal should be generated.
This way you can check what is going on within your code.

I am not sure if I understand you correctly, but in case you try to issue entries on data 2 this wouldn't be possible
as you can only issue trades on data1.

Regards,

ABCTG


Follow me on X Reply With Quote




Last Updated on February 16, 2017


© 2026 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 - Downloads - Top
no new posts