BPt.extensions.SingleConnectivityMeasure.fit_transform#

SingleConnectivityMeasure.fit_transform(X, y=None)[source]#

Fit the covariance estimator to the given time series for each subject. Then apply transform to covariance matrices for the chosen kind.

Parameters
Xlist of n_subjects numpy.ndarray with shapes (n_samples, n_features)

The input subjects time series. The number of samples may differ from one subject to another.

confoundsnp.ndarray with shape (n_samples) or (n_samples, n_confounds), or pandas DataFrame, optional

Confounds to be cleaned on the vectorized matrices. Only takes into effect when vetorize=True. This parameter is passed to signal.clean. Please see the related documentation for details.

Returns
outputnumpy.ndarray, shape (n_subjects, n_features, n_features) or (n_subjects, n_features * (n_features + 1) / 2) if vectorize is set to True.

The transformed individual connectivities, as matrices or vectors. Vectors are cleaned when vectorize=True and confounds are provided.