def generate_random_y_data(samples, dim, ts_no):
Y = np.empty((samples, dim, ts_no));<EOL>for i in range(<NUM_LIT:0>,samples):<EOL><INDENT>for j in range(<NUM_LIT:0>,ts_no):<EOL><INDENT>sample = np.random.randn(dim)<EOL>Y[i,:,j] = sample<EOL><DEDENT><DEDENT>if (Y.shape[<NUM_LIT:2>] == <NUM_LIT:1>): <EOL><INDENT>Y.shape=(Y.shape[<NUM_LIT:0>], Y.shape[<NUM_LIT:1>])<EOL><DEDENT>return Y<EOL>
Generate data:

Input:
------------------

samples - how many samples
dim - dimensionality of the data
ts_no - number of time series

Output:
--------------------------
    Y: np.array((samples, dim, ts_no))