Answers.Body: <p>Use <em>grep</em> to get SNPs that have <code>";"</code> in the name:</p>
  
  <pre><code>&gt;$ grep ";" myMap.txt | cut -f1 -d" " &gt; myBadSNPs.txt
  </code></pre>
  
  <p>Then use plink with <a href="https://www.cog-genomics.org/plink/1.9/filter#snp" rel="nofollow noreferrer">--exclude</a> :</p>
  
  <pre><code>plink --file myFile
  --exclude myBadSNPs.txt
  --out myFileFiltered
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-02-16T15:43:49.977Z
Answers.LastActivityDate: 2018-02-16T15:43:49.977Z
Answers.UserDisplayName: zx8754
Body: <p>I have data in Plink format. I removed Indels using --snps-only command in Plink, but still some snps are as below:</p>
  
  <pre><code>rs58119544;rs5746975    0   16915280    T   A
  </code></pre>
  
  <p>I wonder, how i can get rid of these snps? the correct should be single snps without this (;) sign. Any idea to fix it please?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2018-02-18T15:19:08.420Z
Comments.Text: Hello, I have been trying to figure out what is plink format and it seems that it does not really exist. There are a [lot of plink-flavoured formats](https://www.cog-genomics.org/plink2/formats). Could you [edit] your question and be more specific? Maybe it would be also useful if you would write why are the lines with ";" a problem. If you just want to keep lines without semicolon, you can just do `grep -v ";" my_plink_file > filtered_plink_file`.
Comments.UserDisplayName: Kamil S Jaron
Tags: <plink>
Title: removing indels in plink
ThreadText: # removing indels in plink
  
  (Asked by: username_0 on 2018-02-16)
  
  I have data in Plink format. I removed Indels using --snps-only command in Plink, but still some snps are as below:
  
  ```
  rs58119544;rs5746975    0   16915280    T   A
  
  ```
  
  I wonder, how i can get rid of these snps? the correct should be single snps without this (;) sign. Any idea to fix it please?
  
  **Tags:** plink
  
  > **Comments:**
  > **username_1**: Hello, I have been trying to figure out what is plink format and it seems that it does not really exist. There are a [lot of plink-flavoured formats](https://www.cog-genomics.org/plink2/formats). Could you [edit] your question and be more specific? Maybe it would be also useful if you would write why are the lines with ";" a problem. If you just want to keep lines without semicolon, you can just do `grep -v ";" my_plink_file > filtered_plink_file`.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2018-02-16. Score: 1
  
  Use *grep* to get SNPs that have `";"` in the name:
  
  ```
  >$ grep ";" myMap.txt | cut -f1 -d" " > myBadSNPs.txt
  
  ```
  
  Then use plink with [--exclude](https://www.cog-genomics.org/plink/1.9/filter#snp) :
  
  ```
  plink --file myFile
  --exclude myBadSNPs.txt
  --out myFileFiltered
  
  ```
  
  
  ---
  
  