Uploaded September 2019 | Updated November 2026, 2 hours ago
The mutate function in dplyr lets you add new variables to an existing data frame.
Documentation for for mutate:
dplyr.tidyverse.org/reference/mutate.html
Link to the Kaggle Notebook code used for this video series:
kaggle.com/hamelg/dplyr-in-r
View the whole dplyr in R playlist here:
youtube.com/watch?v=THGFXV4RW8U&list=PLiC1doDIe9rC8RgWPAWqDETE-VbKOWfWl
dplyr cheat sheet from RStudio:
rstudio.com/wp-content/uploads/2015/02/data-wrangling-cheatsheet.pdf
dplyr documentation:
cran.r-project.org/web/packages/dplyr/dplyr.pdf
Follow DataDaft on social media for news and updates:
Twitter: twitter.com/DataDaft
Join the DataDaft Discord to discuss all things data science:
discord.gg/ZS2yPNw
#dplyr #rprogramming #datascience
The mutate function in dplyr lets you add new variables to an existing data frame.
Documentation for for mutate:
dplyr.tidyverse.org/reference/mutate.html
Link to the Kaggle Notebook code used for this video series:
kaggle.com/hamelg/dplyr-in-r
View the whole dplyr in R playlist here:
youtube.com/watch?v=THGFXV4RW8U&list=PLiC1doDIe9rC8RgWPAWqDETE-VbKOWfWl
dplyr cheat sheet from RStudio:
rstudio.com/wp-content/uploads/2015/02/data-wrangling-cheatsheet.pdf
dplyr documentation:
cran.r-project.org/web/packages/dplyr/dplyr.pdf
Follow DataDaft on social media for news and updates:
Twitter: twitter.com/DataDaft
Join the DataDaft Discord to discuss all things data science:
discord.gg/ZS2yPNw
#dplyr #rprogramming #datascience




![How To Use map() in Python
map() is a Python built in that lets you apply or map a function to each element in a list or iterable object. map() is one of the most useful Python built in functions for data analytics, since you will often be working with large sequence data types that need to be transformed in various ways.
Code used in the video:
# Map lets you apply a function to each element of a list
power_level_list = [1000, 4000, 16000, 150, 9001, 1500]
def greater_than_9000(x):
if x > 9000:
return True
return False
mapped = map(greater_than_9000, power_level_list)
print(mapped)
# Print each mapping
for m in mapped:
print(m)
# Extract mapping into new list
mapped_list = [*map(greater_than_9000, power_level_list)]
mapped_list
# Use map with a lambda function
[*map(lambda x: x > 9000, power_level_list)]
* Note: YouTube does not allow greater than or less than symbols in the text description, so the code above will not be exactly the same as the code shown in the video! I will use Unicode large < and > symbols in place of the standard sized ones. .
Videos on Pandas map() operations:
How To Use apply() In Pandas (Python)
https://www.youtube.com/watch?v=smPLY_5gVv4&ab_channel=DataDaft
How To Use applymap() In Pandas (Python)
https://www.youtube.com/watch?v=azF6O_mzaCI&ab_channel=DataDaft How To Use map() in Python](https://i.ytimg.com/vi/E4fSP3cOHCE/mqdefault.jpg)





