intial commit (forked from private repo)
This commit is contained in:
11
extracted_cells/cell10.py
Normal file
11
extracted_cells/cell10.py
Normal file
@ -0,0 +1,11 @@
|
||||
# Features und Zielwerte definieren
|
||||
X = df_encoded.drop(['income', 'income_encoded'], axis=1)
|
||||
y = df_encoded['income_encoded']
|
||||
|
||||
|
||||
# Daten in Trainings- und Testdaten aufteilen
|
||||
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42, stratify=y)
|
||||
|
||||
print(f"Trainingsdaten: {X_train.shape[0]} Beispiele")
|
||||
print(f"Testdaten: {X_test.shape[0]} Beispiele")
|
||||
print(f"Features: {X_train.shape[1]} Merkmale")
|
||||
Reference in New Issue
Block a user