Has anybody figured out how to interfacing Matab with TradeStation or MultiCharts?

Discussion in 'Strategy Development' started by mizhael, Sep 8, 2010.

  1. Hi all,

    I only have MultiCharts trial version so it looks like I cannot post this to TradeStation forum or MultiCharts forum. (Btw, anybody knows if it is possible to post to MultiCharts forum being a trial user?) Any other forums that are active about Easy Language or Power Language discussions?

    But here is my question:

    Has anybody figured out how to interfacing Matab with TradeStation or MultiCharts?

    I would like to use the TradeStation or MultiCharts as graphing devices, and my naive understanding is that:

    If I could, from within Matlab, send time series data and signals to TradeStation or MultiCharts, then TradeStation or MultiCharts should be able to plot the price data as well as signals (the buy/sell arrows). And the zooming and panning features and other studies in TradeStation or MultiCharts are fantastic.

    Any thoughts?

    Thank you!
  2. The easiest way is to use Matlab as a DDE client to TradeStation's DDE server. Get your realtime data into Matlab via ddeadv(). Run your analysis. When a signal is triggered, write it to a file, one line per signal.

    On the Tradestation side, continually poll the file for new lines from your Easylanguage indicator or system.

    I don't know why I bother to reply to you. I doubt you actually implement anything, just ask questions the answers to which you could probably figure out if you gave them ten minutes thought.

    You'll also need ddeinit(). And ddeunadv() and ddeterm() if you want your matlab app to be well-bahaved.
  3. I believe we are talking about different things.

    All I need is to send the time series data/signals from Matlab to TS/MC and display them on TS/MC's chart window.
  4. We don't need it real time.

    In Matlab, we run a simple function called:

    PlotInTS(Dates, Data)

    where Dates are a column vector of dates possibly with timestamps, and data are a column vector of corresponding data.

    And then in TS/MC, you will see the curve, being able to zoom-in, pan, etc.

    And if you use the following function in Matlab:

    PlotInTS1(Dates, Data, Signals)

    you will see buy/sell arrows and number of contracts to buy/sell in TS chart window...

    The date can have intraday timestamps...
    I want to send in my own data from within Matlab because sometimes I transformed the raw price data into some other non-raw data...

    We just want to run a function in Matlab and automatically show plots in TS/MC...

    How to do this?

    Thanks a lot!