In past decades, TCM (Traditional Chinese Medicine) has been widely researched through various methods in computer science, but none digs into huge amount of ancient TCM prescriptions and endless digital TCM information to display the compatible and incompatible relationship among herbs. To meet the challenge and to mine the groups of compatible herbs for further drug exploitation, we explore the property of herbal networks and introduce a novel community detection algorithm concerning both herbal attributes and graph structural factors. First, we calculate the attribute similarity for each paired herbs to construct the herbal graph. Then, a novel community detection algorithm named RWLT (Random Walk & Label Transmission) is proposed to detect herbal groups with near-linear time. The performance of RWLT has been rigorously validated through comparisons with representative methods against randomly created networks, real-world networks and herbal networks. According to the TCM expert, our method is capable of finding groups of Chinese herbs with intensive correlation, and is also able to separate the herbs with mutual incompatibility to be excluded into different communities.