Info

此问题已关闭。 请重新打开它进行编辑或回答。

pairs trading returns matlab

1 次查看(过去 30 天)
alessandro caserta
alessandro caserta 2014-10-16
关闭: MATLAB Answer Bot 2021-8-20
Good morning everyone
I can not understand how they are calculated returns in this part of the code.
s (i: i + N-1, 1) = -reg1.coeff (2). * s (i: i + N-1, 2);
return = sum ([0 0; s (1: end-1, : ). * diff (series2) - abs (diff (s)) * cost / 2], 2);
the prices of the series that I have to examine must be standardized ?
thank you so much for your time and cooperation regards
  1 个评论
Siddharth Sundar
Siddharth Sundar 2014-10-17
编辑:Siddharth Sundar 2014-10-17
Could you give some more information about where you get this piece of code from? If it is some code you are writing, it might be more helpful if you were to attach the complete code with its explanation here. You might also want to provide background information and some insight on what you are looking for in particular.
If you are referring to a File Exchange submission, you might want to contact the author directly as they will have a better idea about the code.

回答(0 个)

此问题已关闭。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by