BPt.Dataset.get_values#

Dataset.get_values(col, dropna=True, decode_values=False, reduce_func=<function mean>, n_jobs=-1)[source]#

This method is used to obtain the either normally loaded and stored values from a passed column, or in the case of a data file column, the data file proxy values will be loaded. There is likewise an option to return these values with and without missing values included.

Parameters
colstr

The name of the column in which to load/extract values for.

dropnabool, optional

Boolean argument, if True, return only non-nan values. If False, return everything regardless of if NaN.

default = True
decode_valuesbool, optional

Boolean argument, if True, then try to return the original values before any encoding, otherwise default of False will return the current loaded values.

default = False
reduce_funcpython function, optional

The passed python function will be applied only if the requested col/column is a ‘data file’. In the case that it is, the function should accept as input the data from one data file, and should return a single scalar value. For example, the default value is numpy’s mean function, which returns one value.

default = np.mean
n_jobsint, optional

As with reduce_func, this parameter is only valid when the passed col/column is a ‘data file’. In that case, this specifies the number of cores to use in loading and applying the reduce_func to each data file. This can provide a significant speed up when passed the number of available cores, but can sometimes be memory intensive depending on the underlying size of the file.

If set to -1, will try to automatically use all available cores.

default = -1
Returns
valuespandas Series

This method returns a single Series with the extracted values for the requested column, which either include or exclude missing values and may be data file proxy values depending on the nature of the requested column.