Answers.Body: <p>I have never used this program, but reading the manual in the link it has to mean the following.</p>
  
  <p>The manual says:</p>
  
  <blockquote>
    <p>Writing <code>-filt_rules_l 'eur.maf&lt;0.05'</code> on the command line would tell the program to remove any variants with <code>eur.maf</code> values less than 0.05 from the reference panel.</p>
  </blockquote>
  
  <p>So, <code>-filt_rules_l 'filter==0'</code> would mean that the program removes any variants with <code>filter</code> values of 0 from the reference panel. In the legend file there should be a column named <code>filter</code>, which are filtered out when the value is 0.</p>
  
  <p>Here is the example legend file, in your case there must be a custom additional column named <em>"filter"</em>:</p>
  
  <pre><code>$ head ALL_1000G_phase1integrated_v3_chr1_impute.legend
  
  id position a0 a1 afr.aaf amr.aaf asn.aaf eur.aaf afr.maf amr.maf asn.maf eur.maf
  rs58108140 10583 G A 0.0407 0.1713 0.1311 0.2071 0.0407 0.1713 0.1311 0.2071
  rs189107123 10611 C G 0.0142 0.0276 0.0140 0.0211 0.0142 0.0276 0.0140 0.0211
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-11-17T10:48:27.647Z
Answers.Text: Thank you, are you suggesting that reference panel has column named "filter"? I will have to check. But I think "eur.maf" column is calculated on the fly from the reference file, need to check.
Answers.UserDisplayName: zx8754
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-11-17T10:55:39.283Z
Answers.Text: If you want to use your command it should. If not it won't work, and you need to find the column on which you want to filter.
Answers.UserDisplayName: benn
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-11-20T09:15:15.647Z
Answers.Text: Yes, sorry I have missed the `_l` bit, meaning this filter works from legend file, which in my case apparently had a modified version of Phase3 legend file with extra `"filter"` column. All makes sense now. Thank you.
Answers.UserDisplayName: zx8754
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-11-16T14:41:49.077Z
Answers.LastActivityDate: 2017-11-20T13:15:08.997Z
Answers.LastEditDate: 2017-11-20T13:15:08.997Z
Answers.UserDisplayName: benn
Body: <p>I went through the manuals and can't find the meaning of the below flag:</p>
  
  <pre><code>-filt_rules_l 'filter==0'
  </code></pre>
  
  <p>Here is the link to manual for this flag: <a href="https://mathgen.stats.ox.ac.uk/impute/filtering_options.html" rel="nofollow noreferrer">filt_rules_l</a></p>
  
  <p>Can anyone explain?</p>
  
  <p>IMPUTE version: </p>
  
  <pre><code>impute_v2.3.1_x86_64_dynamic
  </code></pre>
  
  <hr>
  
  <p><strong>Edit:</strong> The full IMPUTE2 code is irrelevant, I am <strong>not</strong> using the command to impute, I received an imputed data and the script used to impute. This one flag was a mystery to me. I will update the post with impute software version when I find out.</p>
  
Tags: <impute2>
Title: IMPUTE2 missing filter option
ThreadText: # IMPUTE2 missing filter option
  
  (Asked by: username_0 on 2017-11-16)
  
  I went through the manuals and can't find the meaning of the below flag:
  
  ```
  -filt_rules_l 'filter==0'
  
  ```
  
  Here is the link to manual for this flag: [filt\_rules\_l](https://mathgen.stats.ox.ac.uk/impute/filtering_options.html)
  
  Can anyone explain?
  
  IMPUTE version:
  
  ```
  impute_v2.3.1_x86_64_dynamic
  
  ```
  
  ---
  
  **Edit:** The full IMPUTE2 code is irrelevant, I am **not** using the command to impute, I received an imputed data and the script used to impute. This one flag was a mystery to me. I will update the post with impute software version when I find out.
  
  **Tags:** impute2
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2017-11-16. Score: 3 | Accepted answer
  
  I have never used this program, but reading the manual in the link it has to mean the following.
  
  The manual says:
  
  > Writing `-filt_rules_l 'eur.maf<0.05'` on the command line would tell the program to remove any variants with `eur.maf` values less than 0.05 from the reference panel.
  
  So, `-filt_rules_l 'filter==0'` would mean that the program removes any variants with `filter` values of 0 from the reference panel. In the legend file there should be a column named `filter`, which are filtered out when the value is 0.
  
  Here is the example legend file, in your case there must be a custom additional column named *"filter"*:
  
  ```
  $ head ALL_1000G_phase1integrated_v3_chr1_impute.legend
  
  id position a0 a1 afr.aaf amr.aaf asn.aaf eur.aaf afr.maf amr.maf asn.maf eur.maf
  rs58108140 10583 G A 0.0407 0.1713 0.1311 0.2071 0.0407 0.1713 0.1311 0.2071
  rs189107123 10611 C G 0.0142 0.0276 0.0140 0.0211 0.0142 0.0276 0.0140 0.0211
  
  ```
  
  > **Comments:**
  > **username_0**: Thank you, are you suggesting that reference panel has column named "filter"? I will have to check. But I think "eur.maf" column is calculated on the fly from the reference file, need to check.  
  > **username_1**: If you want to use your command it should. If not it won't work, and you need to find the column on which you want to filter.  
  > **username_0**: Yes, sorry I have missed the `_l` bit, meaning this filter works from legend file, which in my case apparently had a modified version of Phase3 legend file with extra `"filter"` column. All makes sense now. Thank you.  
  
  ---
  
  