Page 1 of 1
Sum of Squares
Posted: Mon Aug 29, 2016 5:27 am
by petter
Hi, I'm doing my master thesis now and I wondered if there is a way to calculate the sum of squred differenceof 87 stocks. I want the sum of AB, AC... BC, BD etc. Im doin pairs trading as topic
Re: Sum of Squares
Posted: Mon Aug 29, 2016 8:23 am
by EViews Gareth
You'll have to either calculate each one manually, or write a quick program with a for loop to loop through them, using the @sumsq function.
Re: Sum of Squares
Posted: Mon Aug 29, 2016 8:48 am
by petter
is it difficult to write such a program?
Re: Sum of Squares
Posted: Mon Aug 29, 2016 9:20 am
by EViews Gareth
No.
Read the programming chapter of the Command and Programming Reference, and read through this thread:
http://forums.eviews.com/viewtopic.php?f=5&t=1638
Re: Sum of Squares
Posted: Mon Aug 29, 2016 12:42 pm
by petter
Re: Sum of Squares
Posted: Mon Aug 29, 2016 1:44 pm
by EViews Gareth
If you were using Excel...
Re: Sum of Squares
Posted: Mon Aug 29, 2016 1:50 pm
by petter
I can't figure out the programming, could you help me out?