NexusFi: Find Your Edge


Home Menu

 





Questions and discussion for Sierra Chart ACSIL for Beginners


Discussion in Sierra Chart

Updated
      Top Posters
    1. looks_one Trembling Hand with 43 posts (35 thanks)
    2. looks_two mosalem2003 with 40 posts (0 thanks)
    3. looks_3 1m1k3 with 20 posts (0 thanks)
    4. looks_4 bradhouser with 6 posts (9 thanks)
      Best Posters
    1. looks_one bobwest with 3.5 thanks per post
    2. looks_two bradhouser with 1.5 thanks per post
    3. looks_3 brach with 1 thanks per post
    4. looks_4 Trembling Hand with 0.8 thanks per post
    1. trending_up 28,171 views
    2. thumb_up 53 thanks given
    3. group 30 followers
    1. forum 119 posts
    2. attach_file 25 attachments




 
Search this Thread

Questions and discussion for Sierra Chart ACSIL for Beginners

  #51 (permalink)
 Trembling Hand 
Melbourne, Land of Oz
 
Experience: Advanced
Platform: Sierra Chart, CQG
Broker: CQG
Trading: HSI
Posts: 246 since Jun 2011
Thanks Given: 28
Thanks Received: 360


mosalem2003 View Post
I will check given your modification to the trading system code if it would impact the trading algo study subgraph calculations?

Just to be clear I didn't change any of your calculation logic. Just separated them into two studies to be able to easily test and visualise the different sections.

Let me know the outcome.

Follow me on Twitter Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
REcommedations for programming help
Sierra Chart
ZombieSqueeze
Platforms and Indicators
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
Trade idea based off three indicators.
Traders Hideout
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
 
  #52 (permalink)
mosalem2003
Toronto
 
Posts: 103 since Apr 2019
Thanks Given: 106
Thanks Received: 23

I fully understand. I tested the trading algo study alone without the trading study and I am still observing the unexpected behavior of subgraphs L2_Buyer/Seller. I will continue checking what could be the root cause?

Sent using the NexusFi mobile app

Reply With Quote
  #53 (permalink)
mosalem2003
Toronto
 
Posts: 103 since Apr 2019
Thanks Given: 106
Thanks Received: 23


I have compared again and reviewed the code and the charts. It is noted in the two attached charts that:
The Trading Algo study L2_Seller in this example is not aligned with the L2_Seller that is generated from the same code but using Sierra Spreadsheet ---
Look at how the purple line is changing in both of the charts...
There are 6 events generated from the spreadsheet and it all took place when we close above then we close below the Donchian channel High...
There are only 4 events generated from our ACSIL Trading Algo study...
Notice as well the stairstep changes in both are not aligned and it is as expected from the spreadsheet. I don't think the code is incorrect as it is the same code but one in spreadsheet and the other in ACSIL while we import the array of the Donchian Channel but in the case of the spreadsheet, the donchian channel is a column in the spreadsheet.
One idea to get to the bottom line is to generate the imported array as a subgraph to plot it and compare it with the original Donchian channel and see if they are aligned or not ....










Reply With Quote
  #54 (permalink)
 Trembling Hand 
Melbourne, Land of Oz
 
Experience: Advanced
Platform: Sierra Chart, CQG
Broker: CQG
Trading: HSI
Posts: 246 since Jun 2011
Thanks Given: 28
Thanks Received: 360

!!!!

MATE

Please slowly go through each bar and print to log the values as they process. That is THE ONLY WAY to debug!!!!!

Its all pretty easy to do, I've even given you debug code (true/false code) but for some reason weeks later your still not doing it. For example show me the log prints where the X subgraph is 3752 and you believe it should be 3755.

Follow me on Twitter Started this thread Reply With Quote
  #55 (permalink)
mosalem2003
Toronto
 
Posts: 103 since Apr 2019
Thanks Given: 106
Thanks Received: 23

I do apologize, I thought that this is clear -- However, this is the debug log that you are requesting and it is clear from the log that the array is mis-aligned with the actual Donchian Channel...
DC_High[Index-2] = 3755.75 though in the actual Donchian Channel study it is 3749.25 ..
This implies that the imported array is misaligned with one bar , and it updates earlier than expected.
In this case, we closed above the DC_High at Index-2 and Closed below DC_High at Index-1, so it should make an L2_Seller but due to the change that is earlier than expected the DC_High [Index-2] is changing to equal the DC_High[Index-1] and this will not trigger the condition.. Hope that is clear this time and let me know if you need any more information ... I am not sure why the importing of the array is doing that behavior...







Reply With Quote
  #56 (permalink)
 Trembling Hand 
Melbourne, Land of Oz
 
Experience: Advanced
Platform: Sierra Chart, CQG
Broker: CQG
Trading: HSI
Posts: 246 since Jun 2011
Thanks Given: 28
Thanks Received: 360

I'll have a look tomorrow but what bar date and time is that example from?

Also I'd remove the once per bar code in the Accumulation Trading Algo as well as change sc.CalculationPrecedence = LOW_PREC_LEVEL;

Follow me on Twitter Started this thread Reply With Quote
  #57 (permalink)
mosalem2003
Toronto
 
Posts: 103 since Apr 2019
Thanks Given: 106
Thanks Received: 23

Thanks a lot -- It was Sunday opening bar at 18:00 EST , I tried the changes above and it has the same behavior.



Reply With Quote
  #58 (permalink)
 Trembling Hand 
Melbourne, Land of Oz
 
Experience: Advanced
Platform: Sierra Chart, CQG
Broker: CQG
Trading: HSI
Posts: 246 since Jun 2011
Thanks Given: 28
Thanks Received: 360

OMG!


2021-01-04 17_26_05-Window



Thats why it aint aligned!!!!!

Follow me on Twitter Started this thread Reply With Quote
Thanked by:
  #59 (permalink)
 Trembling Hand 
Melbourne, Land of Oz
 
Experience: Advanced
Platform: Sierra Chart, CQG
Broker: CQG
Trading: HSI
Posts: 246 since Jun 2011
Thanks Given: 28
Thanks Received: 360


Trembling Hand View Post
I would look at your code and when it is executing and with what values before thinking there is an error in ACSIL. I think that assumption is incorrect.... from experience.

OK so the lesson here is a good one.


When writing code keep different function separate and test each one to ensure they work as expected.

IF they don't work as expected have a look at one time it didn't work as expected and look at the values very closely bar by bar to see what values your study is using, what code is producing those values and why. Is the logic correct, are the bar indexes correct that you are referencing. You do that by printing to a log and visualising each bar.

Follow me on Twitter Started this thread Reply With Quote
Thanked by:
  #60 (permalink)
mosalem2003
Toronto
 
Posts: 103 since Apr 2019
Thanks Given: 106
Thanks Received: 23


Thanks a lot @Trembling Hand for your help and great support. Yes, it is a very good lesson to know that the Donchian Channel by Sierra would have that shift. However, the spreadsheet study with the same code was working fine. The donchian channel study as it prints on the subgraph is the correct behavior. It is supposed to switch its value when we make a new high for the range at the next bar after the last.... Will check if they do this by shifting the graph as was shown in the code or it is inherent in the logic.

I will need to change the code reference indexes to align with that shift in the Donchian Channel study from Sierra

Reply With Quote




Last Updated on April 23, 2024


© 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