RightEdge Forums
Main     Home          Members     Calendar     Who's On

Welcome Guest
        



CorrelationTable Expand / Collapse
Message
Posted 3/6/2008 07:01:01 Post #4777
 

Lead DeveloperLead DeveloperLead DeveloperLead DeveloperLead DeveloperLead DeveloperLead DeveloperLead Developer
Calculates Correlations of each two-symbol combination in a WatchList.
Generates a CSV File (C:\temp\cTable.csv) with the complete Correlation Matrix and a CSV file (C:\temp\cList.csv) with a sorted list of correlation coefficients.
The CSV files are ready to read with EXCEL.

Correlation is calculated from the bar-to-bar percentage change (Close-Close) of each instrument.

Note: This "Trading System" contains a Shutdown() procedure only.

The system can be downloaded by clicking here

Posted 10/25/2008 18:19:29 Post #6795
 

Forum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum Guru
Thanks, this is useful.
Posted 10/25/2008 22:55:32 Post #6798
 

DeveloperDeveloperDeveloperDeveloperDeveloperDeveloperDeveloperDeveloper
Just so you know who to give the credit to, this system was uploaded by DrKoch.  It doesn't show on the forum posts but you can see it in the uploaded trading section of the website and on the page for this system.

Thanks,
Daniel

Posted 8/31/2009 17:55:51 Post #9294
 

Forum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum MemberForum Member
Hi , first of all thank you very much Dr. Koch for this excelent code. And here comes my doubt´s :

i´m in doubt about the Bars method used here, first i would like to know if it were used in NewBar method in simulation mode, if it would return only the bars existed so far ??? And if there is a way acessing bars outside the script - so i can make a DLL to make easier to use it. Inputing Symbols name , and start and end time ???

               Thank´s in advance, Vitor .

Posted 1/5/2010 00:14:21 Post #10413
 

Forum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum Guru
This is very useful however I have just tried to run it in Ed2 and notice that InnerList is no longer supported...Just wondering what the changes should be for Ed2


I suspect the old lines:

int cnt = bars.InnerList.Count;
double old = bars.InnerList[i-1].Close;
arr[i] = (bars.InnerList[i].Close / old - 1.0 ) * 100.0;

should be:

int cnt = bars.Count;
double old = bars.LookBack(cnt-(i-1)).Close;
arr[i] = (bars.LookBack(cnt-i).Close / old - 1.0 ) * 100.0;


Is this correct?
thanks
Posted 1/6/2010 13:07:51 Post #10421
 

DeveloperDeveloperDeveloperDeveloperDeveloperDeveloperDeveloperDeveloper
InnerList has been renamed to Items.

Thanks,
Daniel
Posted 1/6/2010 21:35:41 Post #10425
 

Forum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum GuruForum Guru
Great thanks.

I have probs with bar synchronization (which is set to true).

The code checks that the array pairs are same length but they are not. Are there any known bugs with the sync code?

int length = array1.GetUpperBound(0)-1;
if(length != array2.GetUpperBound(0)-1)
{
throw new Exception("length mismatch array1/array2");
}



I have differences of 100 or so bars over 16000 15min bars.....

Setting the Data Start Date to a few weeks back (900-ish bars) has no issues. (I will start another thread about this though)





« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: billb, dplaisted

Permissions Expand / Collapse

All times are GMT -5:00, Time now is 7:29pm

2005-2007 © RightEdge Systems