import pandas as pd
# 1. Create the data (a list of lists)
data = [
[1, 1, 1, 1, 1],
[1, 1, 1, 1, 1],
[1, 1, 5, 1, 1],
[1, 1, 1, 1, 1],
[1, 1, 1, 1, 1]
]
# 2. Convert to a Pandas DataFrame
df = pd.DataFrame(data)
# 3. Use .iat or .iloc to grab the value at row 2, column 2
my_variable = df.iat[2, 2]
print(f”The extracted value is: {my_variable}”)
- Posted by Reggie Visico
- March 14th, 2026




Leave a Reply