Using twinsurr in CRP toolbox with multivariate data
Posted: Thu Feb 14, 2013 12:58
Hi all, I am new to this forum. I have a problem when I try to use twinsurr function as included in the current version of the CRP toolbox. According to the help of this function, Y=twinsurr(X) creates twin surrogates Y based on the vector X
using recurrences. The matrix Y contains 100 columns of 100 twin surrogates. If X is a PxQ matrix, the resulting surrogate matrix is Px100xQ.
But it turns out that whenever I input multivariate data (i.e., say 5 EEG channels with 1000 samples each, X= 5x1000 matrix), I always get the same error, namely: Error using crp (line 300)
First column of the first vector must be monotonically non-decreasing.
I have tried to input X' (the transpose of X) instead, with the same result. Of course I could always make a loop and input the rows of X one by one, but it would be nice if it could be done with one call to the function, as suggested. Any help?
Thanks in advance and thanks a lot also for making the toolbox freely available!
using recurrences. The matrix Y contains 100 columns of 100 twin surrogates. If X is a PxQ matrix, the resulting surrogate matrix is Px100xQ.
But it turns out that whenever I input multivariate data (i.e., say 5 EEG channels with 1000 samples each, X= 5x1000 matrix), I always get the same error, namely: Error using crp (line 300)
First column of the first vector must be monotonically non-decreasing.
I have tried to input X' (the transpose of X) instead, with the same result. Of course I could always make a loop and input the rows of X one by one, but it would be nice if it could be done with one call to the function, as suggested. Any help?
Thanks in advance and thanks a lot also for making the toolbox freely available!