1count_row = df.shape[0] # gives number of row count
2count_col = df.shape[1] # gives number of col count
1>>> df = pd.DataFrame({'col1': [1, 2], 'col2': [3, 4]})
2>>> df.shape
3(2, 2)
4
1print(df.shape)
2# (891, 12)
3
4print(df.shape[0])
5# 891
6
7print(df.shape[1])
8# 12