Add Or Change Columns

We frequently require new calculations that we want to add as new columns. Sometimes we just want to update a column's data type. Let's look at how we can do both in R.

This lesson is coming soon. In the meantime, refer to the provided code examples on GitHub as well as the chapter on data transformation from the book "R for Data Science" (2nd edition).

Drawing
Adding new columns increases the horizontal size of the data frame.
Drawing
Adding a new column and dropping the old ones at the same time.

Last updated