Skip to content

Numpy

How to Calculate a Z-Score in Python (4 Ways)

In this tutorial, you’ll learn how to use Python to calculate a z-score for an array of numbers. You’ll learn a brief overview of what the z-score represents in statistics and how it’s relevant to machine learning. You’ll then learn

Python Get Index of Max Item in List Cover Image

Python: Get Index of Max Item in List

Learn how to use Python to get the index of the max item in a list, including when duplicates exist, using for loops, enumerate, and numpy.

Python Natural Log Cover Image

Python Natural Log: Calculate ln in Python

Learn how to use Python to calculate the natural logarithm, often referred to as ln, using the math and numpy libraries, and how to plot it.

Python Absolute Value Cover Image

Python Absolute Value: Abs() in Python

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.

Python Subtract Two Lists Cover Image

Python: Subtract Two Lists (4 Easy Ways!)

Learn how to use Python to subtract two lists, using the numpy library, the zip function, for-loops, as well as list comprehensions.

Python Split a List (In Half, in Chunks) Cover Image

Python: Split a List (In Half, in Chunks)

Learn how to split a Python list into n chunks, including how to split a list into different sized sublists or a different number of sublists.