I am tring to replace a list value with another list value in a pandas but it raises an error : cannot set using a multi-index selection indexer with a different length than the value
. Is it wrong practice to work with list values in pandas? Thank you
import pandas as pd
cars = {'Brand': ['Honda Civic','Toyota Corolla','Ford Focus','Audi A4'],
'Price': [[123, 123123],[123, 123123],[123, 123123],[123, 123123]]
}
df = pd.DataFrame(cars, columns = ['Brand', 'Price'])
df[1, 'Price'] = [2342, 23423]
print(df)