Extracting common character strings from multiple vectors of different lengths

前端 未结 1 1740
失恋的感觉
失恋的感觉 2020-12-10 08:06

Is there function in R to find the common characters in multiple vectors (of different lengths). For example, if I have 3 vectors...

 a1 <- LETTERS[1:7]
          


        
相关标签:
1条回答
  • 2020-12-10 08:39

    Yes:

    Reduce(intersect,list(a1,a2,a3))
    
    0 讨论(0)
提交回复
热议问题