To determine how many rosemary plants were planted, we first need to find out how many types of herbs were planted. The neighbors planted basil, thyme, rosemary, and oregano, which means there are 4 types of herbs.
Since they planted the same number of each herb and the total number of plants is 52, we can divide the total number of plants by the number of types of herbs:
\[ \text{Number of plants per herb} = \frac{\text{Total number of plants}}{\text{Number of types of herbs}} = \frac{52}{4} = 13 \]
Thus, there are 13 rosemary plants planted in the garden.
So, the answer is 13 rosemary plants.