i want to get the objects which contain a certain value stored in their property list "value" in this case.
import pandas as pd
mydataset = [{"name": "test", "values": ["3", "7", "2"]}, {"name": "test2", "values": ["4", "1", "7"]}]
myvar = pd.DataFrame.from_records(mydataset)
print(myvar[myvar["values"].isin(["3"])])
This codes gives an empty dataframe back.
If i initialize the dataframe with single object it works. How can i filter them when the list is a property value?
You cona use
apply()theis way:which gives