Safir-X versions
Sirtrade 2000
Xs TUTORIALS
Using TradeStation
FAQ List

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Frequently Asked Questions about Safir-X

  • Question:I am interested in possibly purchasing your software but I am concerned that I may be lacking in some of the knowledge needed to use it. Will you or someone else be able to provide tech support if needed? Any possibility that someone from your company will be in the US in the near future for some one on one training?

    Answer:As you may know , we live in France, and seldom travel to your country.
    Of course, we do support for our software, and because we have designed it as an Assistant, this means that you have a few clicks to do to make it work. The technical support therefore is not difficult to do with such software.
    If you are able to use the evaluation version that I suppose you have now downloaded, the commercial version is strictly the same than this one (excepted the limitations that are removed)

    The only point where you have to focus on is the choice of the indicators to make the ASCII file necessary for training.
    An example is provided in the help online, and you may use it with your TS copy to make your ASCII file, then use it with the demo.
    This file will behave exactly as the five files provided. (*.TSD files)
    Once the system build, some copy and paste to a TradeStation system is enough to run it within TradeStation.
    The User manual is all color and more than 100 pages.
    I plan to to a video tutorial soon, but frankly, it is not difficult to use if you have a basic understanding of Easy Language.
    Besides, we offer an Internet (E-Mail) support (then you can ask and send TradeStation examples that may not work for example at the beginning, and I'll explain by the same method how to fix your problem).

    If this product encounters real success, I'll try to do some seminars in your country if there is a need, but not in a near future.

Return to top

  • We understand much of what the program attempts to accomplish but what we don't understand is the very most basic aspect of the program. In other words what are we accomplishing?
    Let me explain what I am looking for and you tell me where/if/how to find it. I have presently a very good system for daytrading the S&P, but
    it is a system that could be better. I use my own indicators
    I would like to find the best values of the various inputs I am using as well as whether to use one type of input or another type of input. Based on this, how would I use your program to improve my system?
    >>
    Yes, but to in the sense that you imagine.
    The software is not a variable value optimizer, but a logic combination optimizer (of the rules that will use these variables).
    This means that the software will rewrite the rules using your indicators in a certainly different manner than what you expect.
    The software works with fixed length indicators (unless you have variable length indicators), but it will vary the rules according to the values taken by each of your indicators.
    This is why I speak of a logic optimizer (and logic finder) and not a hill climbing optimizer like in TradeStation Optimizer.
    The system produced is a fuzzy decision tree where the number of rules is the product of the number of each number of fuzzy set .
    For example, if you use only 4 indicators with 5 fuzzy sets for each, the system produced will be a fuzzy decision tree with 5*5*5*5= 625 trading rules !
    If you prefer, the system will attempt to extract the maximum of knowledge from a very few inputs.
    More, the fuzzy rules are very similar to human thinking
    (if the RSI is medium high and the trend is medium, and the stoch RSI is decreasing and.. then sell).

  • I can see when creating the data file that we provide indicator values and buy/sell signals. Then where or how are the inputs adjusted?
    The ideal buy sell signals are obtained by displacing a trend indicator sign value from a certain amount of time.
    You may use the method that I have explained, and you will see what kind of ideal signal the indicator provides to the ASCII file. (see the indicator above)
    In fact, the inputs are delayed ("now "bars) from the signal in the ASCII file (for training only).


    Return to top

 

  • What is your program providing to me that will aid in the adjustment of the parameters used for trading? One of the questions that comes to mind is that if I am to provide buy/sell signals then how will the program tell me if my buy/sell signals are correct?
    >>
    We may make a distinction with buy_sell signals.Those provided in the ASCII file are very good (as you read bars in advance).
    Now, when you use the software, the test part of the TSD file will not use these buy sell signals, but use those generated from the first part (training) of the TSD file.
    So, the answer is in the performance summary (test column): if the results are good, this means that the buy sell signals were good enough.
    But again, the software do not adjust parameters (like the lookback period of a RSI): it attempts to adjust rules (fuzzy rules) and the fuzzy sets to reach the goal that you have chosen from the performance summary (the field that you highlight in red).

    There are a lot of high math's behind this: Only the convenient and useful part is displayed.
    We have an other software (Safir-X Workshop) that shows what's behind: but it is more difficult to use for the average trader although also powerful because designed for a general purpose.
    The Assistant has the same power, but with the benefit of a full automation and it is specialized on only one thing: to build trading systems according to an objective criterion (from the performance summary).
    What takes 15 min with the Assistant may take several days with the Workshop (as you may test in TradeStation, then train again , then go back to TradeStation, then change the fuzzy sets, then train...).
    All of this is done automatically when you click "Explore" in the Assistant.
    Otherwise, the realtime retraining feature does the same when in TradeStation.
    In this sense, it's a dynamic adaptation of the rule base to the most recent market conditions.

  • Perhaps my questions are far to basic or I am just not informed as to how your program works but I very honestly must say that at this point I don't understand the benefits.
    This concept has never been made available previously, so I understand that it may be difficult to understand when comparing to other products or other methods.
    If we were sure that the Assistant was not valid, we would not offer a free evaluation version like this one without canned indicators and examples that work well only with the typical demo!

  • Also, if you feel I am attempting something that requires more basic knowledge first then please direct me to where I may acquire this knowledge.
    >>
    This is not necessary. Eventually, you may want to read some basic concepts on fuzzy logic, be it is not very useful for the moment, as the fuzzy logic is hidden.
    I you have the book Trading on the Edge ( Guido J.Deboeck), they explain fuzzy logic too.
    You may want to have a look on it.
    You may also load and same some pages from our web site where fuzzy logic is explained, more in detail later.
    (see the Table of Contents).

Return to top

  • In order to determinate answer I will propose a system and you tell me how I can use the "Assistant" to test/improve it. Perhaps after you explain this very basic concept to us then we will comprehend.
    Let us assume that our system is as follows:

Input:Len1(20),Len2(14),BuyStp(1.5),SellStp(.5);
If C Crosses over Average(C,Len1) and SlowD(Len2)<20 then buy at High+BuyStp Stop;
If C crosses below Average(C,Len1) and SlowD(Len2)>80 then exitlong at Low-SellStp Stop;


First, let's change the word "improvement":
The assistant will use your inputs, and build a system from them. The improvement exists if the performance summary is better than with your example system.
In your example, the system is basically a set of two rules: So,it is a very simple one.
What the assistant will make is a system (using the same indicators) with a logic that will be a set of hundred rules.
So, reasoning by asking "how to improve this system" is not a good question for the assistant that thinks: How to build a good trading system (a good logic) by using the considered indicators .
The assistant will start from zero (no rule) and build its own rules.
Obviously, it will find something like what you propose in your example, but not only this.

This is where the improvement will take place:

  1. We provide in both cases the same information.

  2. The basic example above is in fact a 2 rules decision tree.

  3. The Neurofuzzy system after training is a hundred rules (or more) decision tree.

  4. No guidelines are given to the fuzzy system, excepted to maximize the performance summary field

Now, how to to with the ASCII TSD file.
First, we must analyze the available information:
We have:

  • 1)Close,

  • 2)Average Close

  • 3)SlowD

  • 4)Levels for SlowD

  • 5)Measurement from price for entering / exiting the market from high or low

  • 6)Buy stop and Sell stop orders.

Return to top

We must discard 5 & 6 because the assistant builds systems always in the market and place orders on close.
The common practice is to build a system with on close order, and after you may want to improve it with stop and exit order when running it in TradeStation (you may write your stop exit orders in the power editor at the end of the neurofuzzy system, by replacing buy sell on close by anything you want).
This may hurt you, but the Assistant is made to find out a strong logic using only the indicators.
This do not forbid to expect improvements from money management, stop values and so on.
But this is a later step that depends on the trading signal and takes place after the trading signal (i.e the answer from the neurofuzzy system).

So, we stay with 1 to 4.

Now, we have to translate the information for a best understanding by the assistant.
1 and 2 are not normalized.
As the idea prevailing is to compare c and its average, we will subtract them and normalize by dividing by the close.
Our first input will be:
if c<>0 then value1 =(c-average(c,Len1))/c;
This indicator translates your idea in the original example.
More, it will tell how far we are from the average.

3 & 4 deal with SlowD and its levels.
The levels are implicit in fuzzy logic, because we use several fuzzy sets for each input, so we have not to use the levels as inputs (in this sense, you may consider that the assistant will determine variable levels for the stochastic, only by using the stochastic itself).
So, our 2nd input will be
Value2=SlowD(Len2);

(5) is in fact a channel breakout system based on previous h, l values (l for the short side).
Unfortunately, it deals with the bar under construction, not available as a variable in TS (this value is known at the end of the bar, and is used only in realtime)

This is the minimum that we can do with the information that you provide.
You may try the system with only value1 and value2 and see how it behave.
In my opinion, you need to use a greater number of fuzzy sets as we have only two variables .

A better solution could be to exploit your indicators in a more effective manner.
I could want to add one or two more:
value3= value1-value1[1];
Return to top


or if c<>0 then value4=(average(c,len1)- average(c[1],len1))/c;

...to tell if the trend is going up or down (first derivative)

Also, I think that a more wide difference between len1 and len2 could be of benefit (in order to translate long term and short term behaviors.
For example Len1=40, len2=8 (a 5:1 ratio for the lookback periods).

I would like to add one indicator (or two) more, but in this case we could not compare with your original system

A word about buy/sell stop orders;
As I explained above, you may add them later in the TS system.
But there are also stop orders built in in the assistant:
The answer of the fuzzy system (output) is in fact a number above or below 0.
When you train the system, there is a threshold value that is also optimized:
The system buy if output >threshold and sell if output<-threshold.
For each training pass, the assistant tests 20 values of the threshold (0 to 1 by step of 0.05).
You may observe this in the journal file.
Means that if you train during 30 steps in the explore command, the assistant tests 20 *30 =600 trained trading systems and calculates 600 performance summaries, in less than 10 minutes.
This feature (threshold) acts in a similar manner than in your example, with the exception that the threshold value is not the high or low of the bar.

To summary:
You may expect an improvement of any trading system if the indicators used are valid to describe the problem and if you present them as normalized and meaningful values (stay logic in writing the indicators is the mandatory rule).
When (If) you enforce the assistant to follow the initial rules of the example system, you start to diverge from the expected benefit of the assistant: You must not do its job that is to find the logic from your indicators. This is where it is difficult to beat it.

Think that you will better than it is to choose and prepare the inputs value.
Think that it will better and faster than you to build the trading rules.

Return to top

  • Obviously this is only for the sake of an example. There are many times that there is neither a buy signal or a sell signal. How would we improve the above system with your program?
    As I explained above, the Assistant is always in the market when it builds the trading system.
    I can explain why this choice was done to find a strong logic when training, but it is beyond the scope of this FAQ list.
    If you really want to exit, the best is to do it after within TS by running the fuzzy system and see if exit orders may improve or not.
    An other solution would be to train 2 fuzzy systems and exit when the 2nd disagree with the first one.
    But again, we push the logic into a specific one: exiting under some conditions if we act like this (although possible).

  • After reading the manual several times, I am still not clear about how I should proceed to recreate that model, or set up a new one.
    If I understand correctly, there must be an ASCII file that contains a set of values for each bar. The values in the set will be some number of (usually normalized) indicator values that will be used as inputs to the fuzzy modeling system, followed by exactly one output value that indicates whether the next state of the system should be long, flat, or short.

    Yes, with the exception that the next state is either long (buy_sell=+1) or short (buy_sell=-1).
    There is no flat position in this version.

    In regression or neural network terminology, I would call these the independent variables and the dependent variable. I assume that the independent variable include technical indicators such as the values of ADX, MACD, stochastics, etceteras.

    Right.Any technical indicator, fundamental, intermarket...

Return to top

  • Is the output always a category (long/flat/short) or can it be an estimate of some indicator I wish to use (expected percentage price rise)?
    The output is always a category (long or short, i.e +1 or -1).
    Here we use the sign of a trend indicator. You may use the sign of any estimate if it is able to produce ideal buy sell sequences, but not continuous values.
    We have an other product that can train with continuous values of the output(s).The name of this software is "Safir-X Workshop".
    It also produces FZB files and may run also within TradeStation.
    In this sense, it is closer of what you may observe with other Neural Network products (in terms of " how to use it").
    The Assistant, in contrast, is really an assistant like in modern Windows software.
    But with the difference of most Assistants, it leaves the choice to the user of the important things that can have an impact on the result (inputs, preprocessing, choice of the evaluation function, automatic search ) within a few clicks of the mouse.
    All the process hidden behind   is geared to the "saving time" objective and maximization of the computer efficiency.

    Let me now explain why the assistant does not do that:
    Basically, we want an easy to use software to determine buy an sell conditions (that are the core of any trading system), with the less manual tuning, and the more automation within the search (train) phase.So, our choice of a classifier was obvious because any trading system that is always in the market is in fact a classifier.

    More, if you use a continuous output as the prediction goal, you need an interpretation (when to buy, when to sell), according to the prediction made.
    With a classifier like the Assistant is, the buy sell orders are included, and training is done directly in relation with the expected result (the performance Summary field that you choose).
    This is not the case (not always) when you train a predictor and minimize the Root Mean Squared Error (RMSE) .
    A low RMSE is not always directly related to the best performance available.
    So, in a word, the classifier choice and the Performance Summary evaluation function that we estimate as necessary to save time and drive the predictors to the final objective were mandatory choices that we have packaged in a single program : The Assistant for Expert Traders.

  • I can calculate all these values in a spreadsheet, such as MS Excel, or some other programming language.
    Yes, of course.(But it's so easy to do with TradeStation).

  • Or, I can use TradeStation to compute the indicators,
    The best way in our opinion.

  • ...but I think I am still left with the problem of computing the value of the dependent variable, which requires a look ahead into the future. How do I do that in TradeStation?
    This is the tricky point:
    TradeStation is not able to read in advance (excepted with a DLL function, available from this site).
    But TradeStation is able to print (to an ASCII file) several fields in the same row that are calculated at different dates.
    This is what we use.

    If we load an array with all the independant values moved NOW bars behind currentbar., and if we leave the dependant value (do not move), now we have both independant and dependant values stored in a such manner that the dependant value is the prediction value that the neurofuzzy system may learn when using independant values in the same row.
    So, I mean that being on Wednesday, we can tell (if we were) on Monday what should be the answer on Wednesday (now=2).

Return to top

  • The manual also describes another value that follows the dependent variable - on page 26 of the manual it is printed in green and is called "nextpos." Tell me again
    what that is, how it is related to the dependent variable, and how I compute it?
    This is only the expected price variation the bar after the prediction to be made.
    This value is neither an independant or dependant variable. It is used only to calculate the performance summary.
    For sake of clarity, The assistant will try to predict from Monday the buy sell signal for Tuesday, we were enforced to present the dmi difference sign 2 days later (Wednesday) to get a true training value valid for Monday).
    After training, the output (calculated from Monday values) are used for the next day, and so on
    So, knowing close(Tuesday)-close(Monday) allows to calculate the performance summary from the trading signal given on Monday Close..
    This is the only reason of its existence.

  • When I have computed all those values for each bar, I write a space-separated ASCII file with the extension ".TSD." Does it matter where (on the disk) that file is placed?
    You may place this file anywhere.
    From the Option assistant command Panel button, you may define a default path for your TSD files.
    Otherwise, you must load them using the windows dialog box as on page 29 ("Get training data from")

  • At this point I do not need to have TradeStation running (in fact, I may not have used TradeStation at all up to this point) - all I need is the TSD file.
    You do not need TradeStation, excepted to make your TSD file (or not, if you use an other software, or if you use a TSD file example provided).

  • Next I open the SAFIR-X Assistant program from the Windows menu. I select the TSD file and have Assistant open it. Page 29 indicates that the file will have only the necessary number of inputs and exactly one output. What happened to "nextpos"?

    "Nextpos" does not appear as it is not used as an dependant (fortunately!) or a independant variable.
    You may know that nextpos is the last field in a row (mandatory).
    It is ignored by the Assistant, excepted for the performance summary calculations.
    In the same idea, the buy sell field is not used for the test part of the file.

Return to top

Last  modified: July 05, 2007

 


A KISS program

Keep it simple...


Safir-X was designed with the idea of a 100% automated trading system builder.

You only have to put relevant and decorrelated indicators in it.

See if it works, if not, try with other data, indicators.

It will only take 10 minutes of your time, and thinking too much about it will take you hours.

If relevant relationships exist in your data, it will find them in a snap.

If it does not, your data are wrong, so do not insist:... Change them,and try again.

Use classical indicators, they will work fine, better than what you might expect.

ADX, stochastics, CCI, %B, RSI are very good choices.

Mix lookback periods to avoid redundancy.

Also use  a first difference of one or two of them.

Keep the zig zag function ( the ideal buy sell signal) compliant  with your indicators ( do not use a RSI(close,5) to make leand an average 100 bars zig zag length).

 

 

 

Previous Up