Tradestation easylanguage indicators to Sierra Charts - Sierra Chart | futures io social day trading
futures io futures trading


Tradestation easylanguage indicators to Sierra Charts
Updated: Views / Replies:2,965 / 22
Created: by Renko123 Attachments:1

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 1  
 
Thread Tools Search this Thread
 

Tradestation easylanguage indicators to Sierra Charts

  #11 (permalink)
Trading for Fun
Washington, DC USA
 
Futures Experience: Intermediate
Platform: Tradestation, SC
Favorite Futures: NQ, ES, YM
 
Posts: 56 since Nov 2013
Thanks: 9 given, 2 received

Thanks for all the help.
Things are looking better.
I have put the MRO headache on hold until some smaller issues can be solved and come back to the MRO issue later

The issue im working on now is:
In Tradestation if i wanted to access a previous value in a non persistent variable i would use.

value2 = average / 18; put in a new value
value3 = value2[1]; read out the previous value from the value2

In Sierra how would I get the previous value from value2 ?

Reply With Quote
The following user says Thank You to Renko123 for this post:
 
  #12 (permalink)
Trading for Fun
Washington, DC USA
 
Futures Experience: Intermediate
Platform: Tradestation, SC
Favorite Futures: NQ, ES, YM
 
Posts: 56 since Nov 2013
Thanks: 9 given, 2 received

I see that my post has gotten 300 + views but only 2 people stepped up to offer assistance.
Thanks again to those 2 people.

Anyway, after finding out that its a waste of time to even ask Sierra support for assistance with using their product.
Tradestation and Sierra support is like night and day.
Tradestation support steps up right away to help the users of their software, Sierra will tell you a "Its easy to program" and then don't post any example code and then never reply to the post again.


After a lot of cursing, I`m getting closer to getting the TS indicator ported over..
Now I need to know how to plot a point at a specified price on the chart at sc.index current bar.

I`m temped to just give up on Sierra charts and stick with Tradestation.
The EL language makes common sense and if you have a coding problem, the techs step up right away to answer your post until the problem is solved.

Sierra support, forget about it.

Reply With Quote
 
  #13 (permalink)
Elite Member
Netherlands
 
Futures Experience: Advanced
Platform: Ensign, Multicharts
Favorite Futures: SP500
 
Posts: 95 since Nov 2009
Thanks: 66 given, 56 received



Renko123 View Post
Thanks for all the help.
Things are looking better.
I have put the MRO headache on hold until some smaller issues can be solved and come back to the MRO issue later

The issue im working on now is:
In Tradestation if i wanted to access a previous value in a non persistent variable i would use.

value2 = average / 18; put in a new value
value3 = value2[1]; read out the previous value from the value2

In Sierra how would I get the previous value from value2 ?

This is exactly the same in Sierra. You can get previous values in an array the same way.

value3 = value2[1];

So you have to use arrays to store the values.

Reply With Quote
 
  #14 (permalink)
Trading for Fun
Washington, DC USA
 
Futures Experience: Intermediate
Platform: Tradestation, SC
Favorite Futures: NQ, ES, YM
 
Posts: 56 since Nov 2013
Thanks: 9 given, 2 received


ehlaban View Post
This is exactly the same in Sierra. You can get previous values in an array the same way.

value3 = value2[1];

So you have to use arrays to store the values.

Yes, in Sierra have to create an array and loop to fill it.
double value2[11];
for ( int i = sc.Index; i >= sc.Index -10; i--)
{
value2[i] = fabs (sc.Close[i -10] - sc.Close[i]);
}

However in TS you don't have to deal with creating an array and looping to fill it.
value2= fabs (sc.Close[i -10] - sc.Close[i]);
and when you need that value later just call it.
value3=value2[1];

Unless, I`m wrong with having to loop to fill the array in Sierra?

How would I plot a dot on the chart on the current bar with Sierra?

In TS it is simple:
PLOT1 (value3, "ExitPrice") ;

Thanks for all your help again.

Reply With Quote
 
  #15 (permalink)
Elite Member
Alesia E.U.
 
Futures Experience: Intermediate
Platform: Sierra chart
Favorite Futures: Futures
 
Posts: 166 since Feb 2011
Thanks: 139 given, 109 received

SCSubgraphRef PLOT = sc.Subgraph[0];


// Section 1 - Set the configuration variables and defaults
if (sc.SetDefaults)
{


PLOT.Name = "ExitPrice";
PLOT.DrawStyle = DRAWSTYLE_POINT;


return;
}
// Section 2 - Do data processing here


PLOT[sc.Index]=value3;

Reply With Quote
The following user says Thank You to crazybears for this post:
 
  #16 (permalink)
Elite Member
Netherlands
 
Futures Experience: Advanced
Platform: Ensign, Multicharts
Favorite Futures: SP500
 
Posts: 95 since Nov 2009
Thanks: 66 given, 56 received


Renko123 View Post
Yes, in Sierra have to create an array and loop to fill it.
double value2[11];
for ( int i = sc.Index; i >= sc.Index -10; i--)
{
value2[i] = fabs (sc.Close[i -10] - sc.Close[i]);
}

However in TS you don't have to deal with creating an array and looping to fill it.
value2= fabs (sc.Close[i -10] - sc.Close[i]);
and when you need that value later just call it.
value3=value2[1];

Unless, I`m wrong with having to loop to fill the array in Sierra?

How would I plot a dot on the chart on the current bar with Sierra?

In TS it is simple:
PLOT1 (value3, "ExitPrice") ;

Thanks for all your help again.

Look at the source code i provided especially at calcArray
In Sierra you normally don't have to fill an array with a loop as it's the same as in TS or Easylanguage.

Just define an array.
While calculating your indicator (it starts from the first chart point) fill your array as well just like value2[sc.Index]
if you have defined a name and drawstyle for calcArray it plots automatically, like in TS
calcArray.Name = "myLine";
calcArray.DrawStyle = DRAWSTYLE_LINE;

Reply With Quote
 
  #17 (permalink)
Trading for Fun
Washington, DC USA
 
Futures Experience: Intermediate
Platform: Tradestation, SC
Favorite Futures: NQ, ES, YM
 
Posts: 56 since Nov 2013
Thanks: 9 given, 2 received


crazybears View Post
SCSubgraphRef PLOT = sc.Subgraph[0];


// Section 1 - Set the configuration variables and defaults
if (sc.SetDefaults)
{


PLOT.Name = "ExitPrice";
PLOT.DrawStyle = DRAWSTYLE_POINT;


return;
}
// Section 2 - Do data processing here


PLOT[sc.Index]=value3;

Since I already have a reference that uses sc.Subgraph[0].
I used sc.Subgraph[1] unless multiple refs can use the same sc.Subgraph[0]?
Plot still isn't applied at the correct place on the chart.
 
Code
SCSubgraphRef Sideways = sc.Subgraph[0];
SCSubgraphRef bullish  = sc.Subgraph[1];

bullish.Name = "Bullish"; 
bullish.DrawStyle = DRAWSTYLE_POINT;

futher down into the processing code I applied.
bullish[sc.Index] = 4155.00;  // hard coded to test if plot shows up.

The plot does not show up at 4155.00, it shows up at the top of the bar only
See image.
Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).

Reply With Quote
 
  #18 (permalink)
Trading for Fun
Washington, DC USA
 
Futures Experience: Intermediate
Platform: Tradestation, SC
Favorite Futures: NQ, ES, YM
 
Posts: 56 since Nov 2013
Thanks: 9 given, 2 received


ehlaban View Post
Look at the source code i provided especially at calcArray
In Sierra you normally don't have to fill an array with a loop as it's the same as in TS or Easylanguage.

Just define an array.
While calculating your indicator (it starts from the first chart point) fill your array as well just like value2[sc.Index]
if you have defined a name and drawstyle for calcArray it plots automatically, like in TS
calcArray.Name = "myLine";
calcArray.DrawStyle = DRAWSTYLE_LINE;

I looked at it and it just confuses me more.
Are you saying that if I do this:

double value2[6]; declare array
value2[sc.Close[sc.Index -3] - sc.Close[sc.Index]] ;

That it will fill all 7 place holders in the array without me having to "for" loop thru manually and fill it?

I tried that and got an "Error: expression must have and integral or enum type".

Reply With Quote
 
  #19 (permalink)
Elite Member
Netherlands
 
Futures Experience: Advanced
Platform: Ensign, Multicharts
Favorite Futures: SP500
 
Posts: 95 since Nov 2009
Thanks: 66 given, 56 received

Working with Arrays and Looping - Sierra Chart

No

sc.Subgraph[0]
sc.Input[0]
are arrays, so:

SCSubgraphRef IndicatorLine = sc.Subgraph[0]; //Output line an first array
SCInputRef firstInput = sc.Input[0]; // Input for Indicator
SCFloatArrayRef calcArray = IndicatorLine.Arrays[0]; // can be used for calculations if needed

are all array definitions with a normal name like calcArray.
Those arrays are always the same size as there are bars in the chart. When loaded with auto looping
and sc.Index everything is calculated from the first bar to the last. sc.Index keeps track of it.

if you want to lookup values 3 bars to the left [sc.Index-3] and you start from 0 you should do something like:

if (sc.Index < 2) Filt[sc.Index] = sc.BaseDataIn[SC_LAST][sc.Index];
else Filt[sc.Index] = c1 * (sc.BaseDataIn[SC_LAST][sc.Index]


Renko123 View Post
I looked at it and it just confuses me more.
Are you saying that if I do this:

double value2[6]; declare array
value2[sc.Close[sc.Index -3] - sc.Close[sc.Index]] ;

That it will fill all 7 place holders in the array without me having to "for" loop thru manually and fill it?

I tried that and got an "Error: expression must have and integral or enum type".


Reply With Quote
 
  #20 (permalink)
Trading for Fun
Washington, DC USA
 
Futures Experience: Intermediate
Platform: Tradestation, SC
Favorite Futures: NQ, ES, YM
 
Posts: 56 since Nov 2013
Thanks: 9 given, 2 received



Renko123 View Post
Since I already have a reference that uses sc.Subgraph[0].
I used sc.Subgraph[1] unless multiple refs can use the same sc.Subgraph[0]?
Plot still isn't applied at the correct place on the chart.
 
Code
SCSubgraphRef Sideways = sc.Subgraph[0];
SCSubgraphRef bullish  = sc.Subgraph[1];

bullish.Name = "Bullish"; 
bullish.DrawStyle = DRAWSTYLE_POINT;

futher down into the processing code I applied.
bullish[sc.Index] = 4155.00;  // hard coded to test if plot shows up.

The plot does not show up at 4155.00, it shows up at the top of the bar only
See image.
Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).

Ok, I got the plot working now.
Issue was the setting in the study on the chart.
Even tho i had the bullish.DrawStyle = DRAWSTYLE_POINT the chart was overriding the code by having the "point high" selected in the DrawStyle.

Thanks for the help. the plotting problem is fixed.

Reply With Quote

Reply



futures io > > > > Tradestation easylanguage indicators to Sierra Charts

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Jigsaw Trading: TBA

Elite only

FuturesTrader71: TBA

Elite only

NinjaTrader: TBA

Jan 18

RandBots: TBA

Jan 23

GFF Brokers & CME Group: Futures & Bitcoin

Elite only

Adam Grimes: TBA

Elite only

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
TradeStation EasyLanguage RadarScreen Indicator Code kitewind TradeStation 3 May 23rd, 2014 06:59 AM
Sierra charts and IB - order not cancelled in Sierra deepgreen Sierra Chart 5 December 22nd, 2013 10:08 AM
Global Variables (GV) in EasyLanguage for TradeStation/MultiCharts Big Mike EasyLanguage Programming 19 October 29th, 2013 04:07 PM
Tradestation 9 Easylanguage to Multi-charts easy language dtman EasyLanguage Programming 5 April 8th, 2012 02:07 PM


All times are GMT -4. The time now is 02:51 AM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
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.
no new posts
Page generated 2017-12-15 in 0.15 seconds with 20 queries on phoenix via your IP 54.226.132.197