hypertools.tools.format_data

hypertools.tools.format_data(x, ppca=False)[source]

Formats data into a list of numpy arrays

This function is useful to identify rows of your array that contain missing data or nans. The returned indices can be used to remove the rows with missing data, or label the missing data points that are interpolated using PPCA.

Parameters:

x : numpy array, dataframe or (mixed) list

The data to convert

ppca : bool

Performs PPCA to fill in missing values (default: False)

Returns:

data : list of numpy arrays

A list of formatted arrays