Reshaping DataFrames with Dummies
Explore various options for manipulating and reshaping a DataFrame.
We'll cover the following...
Various patterns pop up when we start analyzing data, giving us the tools that we need to deal with them.
Dummy columns
Creating dummy columns is one way to convert a categorical column into numeric columns. The process is straightforward. If we have a column that has repeated string values, we can create a new column for each of those values and insert a 1 or a 0 in each new column if it corresponds to the original value.
We’ll ...