0

I have to remove rows that contain the pipe symbol.

My Input:

 > gene_anotation   

    probeset_id GeneSymbol Ensembl_gene_id
    17406395            Arfip1            <NA>
    17393207 LOC101056658|Ahcy            <NA>
    17467690             Ptcd3            <NA>
    17400375              Ctss            <NA>

My Expected output:

 > gene_anotation   

    probeset_id GeneSymbol Ensembl_gene_id
    17406395            Arfip1            <NA>
    17467690             Ptcd3            <NA>
    17400375              Ctss            <NA>

I already tried these, but with no results:

gene_anotation[!grepl("|", gene_anotation$GeneSymbol),]

or

gene_anotation[!gene_anotation$GeneSymbol == "|", ]
Sotos
  • 51,121
  • 6
  • 32
  • 66
ASF
  • 269
  • 2
  • 10

0 Answers0