Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Convert tick data in NT format

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Convert tick data in NT format

    Hi I am a user of tick data company and the format in txt do not have ; separate field for NT, somebody knows a convert tool??

    Thank you very much

    #2
    I suggest to take a look at the two forum threads below.


    JasonNinjaTrader Customer Service

    Comment


      #3
      historical data with Tradestation2000i

      Hi I see that I can dowload historical data from tradestation but I have ts2000i and when insert tradestation file It do not appear the strategy.. can ninja trader support to give us the code to construct that strategy, in europe we have still problems with new version of ts8.

      thank you very much

      Comment


        #4
        Unfortunately we don't provide a migration service TS8->TS2000. May be the community can contribute?

        Here is the text of the TS8 NTDataDownload strategy as a starting point:
        Code:
        { Copyright (C) 2006, NinjaTrader LLC <[email protected]> }
        DefineDLLFunc:  "shell32.dll", int, "SHGetFolderPathA", int, int, int, int, lpstr;
        [LegacyColorValue = true]; 
         
        variable: barsCount(0),         { # of bars processed }
           buffer(""),                   { output buffer }
           err(0),                        { error code }
           hoursOffset(0),              { hours offset to EST timezone(New York) }
           linesInBuffer(0),            { actual # of lines in output buffer }
           maxLinesInBuffer(100),       { max. # of lines in output buffer }
           outputFile(""),              { output file name }
           num(0),
           importFolder("");            { name of import folder }
        
        if BarInterval <> 1 or BarType <> 1 then begin
            value0 = Text_New(Date, Time, High, "NTDownloadData can only be used on 1 minute interval");
        end else begin
            if importFolder = "" then begin
                importFolder = "                                                 ";
                importFolder = importFolder + "                                                 ";
                importFolder = importFolder + "                                                 ";
                importFolder = importFolder + "                                                 ";
                importFolder = importFolder + "                                                 ";
            
                { get users's app data directory: SHGetFolderPath(0, CSIDL_PERSONAL, 0, SHGFP_TYPE_CURRENT, folder) }
                err = SHGetFolderPathA(0, 5, 0, 0, importFolder);
                outputFile = importFolder;
                 outputFile = outputFile + "\NinjaTrader 6.5\db\import\" + GetSymbolName + ".txt";
            end;
         
            if barsCount = 0 then
                 FileDelete (outputFile);
             
            buffer = buffer + NumToStr (1900 + Year(date), 0);
             
            num = Month (date);
            if num < 10 then
                 buffer = buffer + "0";
            buffer = buffer + NumToStr (num, 0);
             
            num = DayOfMonth (date);
            if num < 10 then
                 buffer = buffer + "0";
            buffer = buffer + NumToStr (num, 0) + " ";
             
            num = Time - hoursOffset * 100;
            if num < 10 then begin
                buffer = buffer + "000";
            end else if num < 100 then begin    
                buffer = buffer + "00";
            end else if num < 1000 then
                buffer = buffer + "0";
            buffer = buffer + NumToStr (num, 0) + "00;";
             
            buffer = buffer + NumToStr (open, 4) + ";";
            if BarType <> 0 then begin
                 buffer = buffer + NumToStr (high, 4) + ";";
                 buffer = buffer + NumToStr (low, 4) + ";";
                 buffer = buffer + NumToStr (close, 4) + ";";
            end;
            buffer = buffer + NumToStr (ticks, 0) + NewLine;
             
            linesInBuffer = linesInBuffer + 1;
            if linesInBuffer > maxLinesInBuffer or LastBarOnChart then begin 
                 FileAppend(outputFile, buffer);
                 linesInBuffer = 0;
                 buffer = "";
            end;
             
            barsCount = barsCount + 1;
        end

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by cmtjoancolmenero, Yesterday, 03:58 PM
        4 responses
        23 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Started by Brevo, Today, 01:45 AM
        1 response
        14 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Started by rjbtrade1, 11-30-2023, 04:38 PM
        2 responses
        73 views
        0 likes
        Last Post DavidHP
        by DavidHP
         
        Started by suroot, 04-10-2017, 02:18 AM
        5 responses
        3,021 views
        0 likes
        Last Post NinjaTrader_Gaby  
        Started by Stanfillirenfro, Today, 07:23 AM
        1 response
        7 views
        0 likes
        Last Post NinjaTrader_Gaby  
        Working...
        X