Hel lo I have a df such as :
Col1 Col2
Group1 Seq_1:(+)Sp1
Group1 Prot_1-A
Group1 Seq_1:(-)Sp2
Group1 Prot_1B
Group1 Seq_2:(-)Sp2
Group1 Seq_1:(+)Sp3
Group1 Prot_1C
Group2 Seq_1:Sp5
Group2 Prot_1-E
Group2 Prot_1G
Group2 Seq_2:(+)Sp5
Group2 Seq_1:(+)Sp6
Group3 Seq_1:(-)Sp7
Group3 Prot_1H-AB
Group3 Seq_1:(+)Sp7 Prot_1Y
and I would like grouby each group in Col1:
- count the number of different Col2 values that do not have a (+) or a (-) in its element.
- count the number of different Col2 values that do have a (+) or a (-) in its element.
ex Group1:
- Nb seq with (+) or (-) = 4
- Nb seq without (+) or (-) = 3
Group3:
- Nb seq with (+) or (-) = 2
- Nb seq without (+) or (-) = 1