Answers for "pandas to dummy"

0

how to get dummies in a dataframe pandas

df = pd.get_dummies(df, columns=['type'])
Posted by: Guest on September-03-2020
0

pandas dummy classification data

from sklearn.datasets import make_classification
import pandas as pd
X, y = make_classification(n_samples=10, n_features=4, n_classes=2, random_state=123)
Posted by: Guest on May-22-2021

Python Answers by Framework

Browse Popular Code Answers by Language