Pandas: Iterate over a Pandas Dataframe Rows
Learn how to use Python and Pandas to iterate over rows of a dataframe, why vectorization is better, and how to use iterrows and itertuples.
Learn how to use Python and Pandas to iterate over rows of a dataframe, why vectorization is better, and how to use iterrows and itertuples.
Learn how to replace an item or items in a Python list, including how to replace at an index, replacing values, replacing multiple values.
Learn how to use Python and Pandas to convert a dataframe column values to strings, including how to optimize for memory and efficiency.
Learn how to use Python to remove duplicates from a list, including how to maintain order from the original list, using seven methods.
Learn how to use the Python strftime method to convert datetime objects into strings, and how to use f-strings to convert dates to strings.
Learn how to use the Python floor function to round numbers down. Learn the differences between Python 2 and 3 and how to do floor division.
Learn how to calculate a Python absolute value using the abs() function, as well as how to calculate in numpy array and a pandas dataframe.
Learn how to calculate the variance of a variable in Pandas, including how to calculate for a single column, multiple or a whole dataframe.
Learn how to use Python to convert a dictionary into a list of tuples, using list comprehensions, the zip function, and collections.
Learn how to use Python to shuffle a list, including being able to reproduce a given result and shuffling Python lists of lists.
Learn how to use Python to pretty print a dictionary using the pprint and json libraries, including nested dictionaries and saving to a file.
Learn how to use Python to delete a file or a directory, using the os, shutil, and pathlib libraries. Also learn how to handle errors.