Trend following Code for TS

Grey1

Senior member
Messages
2,190
Likes
202
another addition to your library
 

Attachments

  • trend.jpg
    trend.jpg
    75.8 KB · Views: 252
opps this is the code
 

Attachments

  • trend following indicator.doc
    24 KB · Views: 147
Grey1,

I copied the code and tried to veriy in Tradestation and recieved and error "Word not recognized by Easy Language", referring to "XPOINTS" in the code.
 
There needs to be either:

A statement in the code to say what XPOINTS refers to ie
XPOINTS = close - open;

or there needs to be a function called XPOINTS that has previously been verified.


Paul
 
XPOINTS is completely undifined in the source code so I'd imagine that whoever wrote it originally had a function called XPOINTS already programed on their machine. Normally if you write and then save a TS file it gives you the option to save aditional functions that are required to support the main code. In this case all we see is the source code for the trend following indicator and no code for XPOINTS hence it wont run.

Steve.
 
Grey 1

if it verifies as a code on your machine,
export the file with export wizard in power editor .. this should sort it ?
this is the best way of making shure its exaclty the same as on your own machine .

file. import export storage file (ELS )

load the indicator/function/paint bar ? from drop-down..... next .....browse in file name select a name to remember say zz ...save this.
can now be transfered as an attachment and opened automatically in TS in power editor or attached on the t2win B.B. sometimes transferring pasted codes will not verify as they can have dll`s

John.
 
Top