I'm experimenting with pandas. I'm trying to create a simple object that represents the data i want to work with. To do so I've written the code below to create an object but I'm getting:
TypeError: test_df() missing 1 required positional argument: 'self
on line 13. I'm not able to figure out what I'm doing wrong. Perhaps something conceptual about the class declaration I'm not getting. Any help is much appreciated.
import pandas as pd
class ICBC():
def __init__(self, name, path):
self.name = name
self.df = pd.read_csv(path)
def test_df(self):
print(self.df.info)
mov = ICBC("matisalimba3","z:\devs\py\movimientos.csv")
ICBC.test_df() <- This is line 13