I am trying to **find frequent patterns** with **pyfpgrowth** library and 
**pandas**, first i created a dataframe with one column,each row is a transaction here is the code:

```
import pyfpgrowth
import pandas as pd
import numpy as np
data = pd.read_csv("itemsets1.csv")
data = pd.DataFrame(data)
data.columns = ['itemsets']
data

```

output:
![enter image description here](https://i.stack.imgur.com/j3Orb.png)

```
patterns = pyfpgrowth.find_frequent_patterns(data['itemsets'],6)
patterns

```

output:

```
{(' ',): 6, (' ', '1'): 8, ('1',): 9, ('1', '8'): 6, ('8',): 6}

```

actually i have two problems here the first is that the algorithm takes space as an item which is wrong,the second is in the frequence of items for example the item one '1' appears only once, but in the output it shows 9 also wrong, need some help please