AutomatedEDA
High-level interface for the complete preprocessing workflow.
Class
from lochan_eda import AutomatedEDA
eda = AutomatedEDA()Methods
prepare()
prepare( X: pd.DataFrame, target=None, exclude=None, split=True, test_size=0.2, random_state=42, stratify=None)Provides a high-level interface for the common tabular preprocessing workflow.
Example
X_train, X_test, y_train, y_test = eda.prepare(
df,
target="target",
exclude=["id", "name"],
split=True,
test_size=0.2,
random_state=42,
stratify=df["target"]
)fit()
fit(X: pd.DataFrame, y: pd.Series=None)Fits the preprocessing workflow using training data before it is reused for transformation.
Example
eda.fit(X_train, y_train)transform()
transform(X: pd.DataFrame, y: pd.Series=None)Applies the fitted preprocessing workflow to data.
Example
X_train, y_train = eda.transform(X_train, y_train)
X_test, y_test = eda.transform(X_test, y_test)Train / test pattern
eda.fit(X_train)
X_train = eda.transform(X_train)
X_test = eda.transform(X_test)