watex.datasets.load_edis#

watex.datasets.load_edis(*, return_data=False, as_frame=False, key=None, tag=None, samples=None, data_names=None, **kws)[source]#

Load SEG-Electrical Data Interchange (EDI) object

EDI data is a sample of data collected in Huayuan county in China.

Parameters:
  • return_data (bool, default=False) – If True, returns data in array-like 1D instead of a Boxspace object. Note that the data is only a collection of EDI-objects from watex.edi.Edi

  • as_frame (bool, default=False) – If True, the data is a pandas DataFrame including columns with appropriate dtypes (numeric).

  • samples (int, default=None) – The sample of data to retrieve.

  • (tag (None) – tag and data_names do nothing. just for API purpose and to allow fetching the same data uing the func:~watex.datasets.fetch_data since the latter already holds tag and data_names as parameters.

  • data_names) (None) – tag and data_names do nothing. just for API purpose and to allow fetching the same data uing the func:~watex.datasets.fetch_data since the latter already holds tag and data_names as parameters.

  • key (str, {'site', 'edi', 'latitude', '*', 'longitude'}, default='edi') – Kind of EDI-data to fetch. If the star is given, fetch all the data on a single frame

Returns:

data – Dictionary-like object, with the following attributes. data : {ndarray, dataframe} of shape (50, 4)

The data matrix. If as_frame=True, data will be a pandas DataFrame.

feature_names: list

The names of the dataset columns.

frame: DataFrame of shape (50, 4)

Only present when as_frame=True. DataFrame with data and no target. .. versionadded:: 0.1.2

DESCR: str

The full description of the dataset.

filename: str

The path to the location of the data. .. versionadded:: 0.1.2

Return type:

Boxspace

Examples

>>> from watex.datasets.dload import load_edis
>>> load_edis ().frame [:3]
                edi
0  Edi( verbose=0 )
1  Edi( verbose=0 )
2  Edi( verbose=0 )
>>> load_edis (as_frame =True, key='longitude latitude', samples = 7)
    latitude   longitude
0  26.051390  110.485833
1  26.051794  110.486153
2  26.052198  110.486473
3  26.052602  110.486793
4  26.053006  110.487113
5  26.053410  110.487433
6  26.053815  110.487753