# convert 23and me to vcf

**URL:** https://help.galaxyproject.org/t/convert-23and-me-to-vcf/378
**Category:** Uncategorized
**Tags:** bcftools
**Created:** [January 10, 2019, 1:53pm UTC](https://help.galaxyproject.org/t/convert-23and-me-to-vcf/378 "2019-01-10T13:53:00Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![cwray](https://avatars.discourse-cdn.com/v4/letter/c/8e7dd6/32.png) [@cwray](https://help.galaxyproject.org/u/cwray)
#### Post date: [January 10, 2019, 1:53pm UTC](https://help.galaxyproject.org/t/convert-23and-me-to-vcf/378/1 "2019-01-10T13:53:00Z")

</div>

Trying to convert a 23andme tsv file to vcf using bcftools convert to vcf. Building a lesson for UG class.

I get this error: Fatal error: Exit code 255 ()

–tsv2vcf requires the --samples option

python: : Unknown error 59090864

Can someone specify proper options to get the bcf conversion to work?

---

<div class="post-metadata">

### Author: ![dave](https://sea2.discourse-cdn.com/flex020/user_avatar/help.galaxyproject.org/dave/32/32_2.png) [@dave](https://help.galaxyproject.org/u/dave)
#### Post date: [January 10, 2019, 4:00pm UTC](https://help.galaxyproject.org/t/convert-23and-me-to-vcf/378/2 "2019-01-10T16:00:56Z")

</div>

This [pypi package](https://pypi.org/project/23andme-to-vcf/) might give you better results.

If that fails, there’s also a [perl script](https://github.com/arrogantrobot/23andme2vcf) that I have successfully used.

---

<div class="post-metadata">

### Author: ![cwray](https://avatars.discourse-cdn.com/v4/letter/c/8e7dd6/32.png) [@cwray](https://help.galaxyproject.org/u/cwray)
#### Post date: [January 10, 2019, 4:17pm UTC](https://help.galaxyproject.org/t/convert-23and-me-to-vcf/378/3 "2019-01-10T16:17:32Z")

</div>

I knew about the pypi and perl script but

I was hoping to get my students to execute this within Galaxy if at all possible

---

<div class="post-metadata">

### Author: ![jennaj](https://sea2.discourse-cdn.com/flex020/user_avatar/help.galaxyproject.org/jennaj/32/27_2.png) [@jennaj](https://help.galaxyproject.org/u/jennaj)
#### Post date: [January 10, 2019, 10:53pm UTC](https://help.galaxyproject.org/t/convert-23and-me-to-vcf/378/4 "2019-01-10T22:53:59Z")

</div>

To use the Galaxy wrapped **BCFtools convert to vfc** tool/function with `tsv` input, both the reference genome and sample information need to be specified at runtime. This is noted on the tool form – highlighted in the screenshot attached below.

Sample names can be entered directly on the form or supplied as a “list” dataset file in a tabular format. Include/exclude are both possible. For help with what a sample content represents and the proper formatting, please see: [http://samtools.github.io/bcftools/bcftools.html#convert](http://samtools.github.io/bcftools/bcftools.html#convert) (is linked from the bottom of the tool form).

![bcftools-sample-input](https://us1.discourse-cdn.com/flex020/uploads/galaxy/original/1X/ed565e790d7996ab9eb322e8291ea1494ead5a8a.png)

If you run into problems even with those entered, double check both of the below are true:

1. The **reference genome** fasta has the same exact chromosome identifiers on the “\>” title lines as the VCF includes for mapping positions. No extra whitespace or description content + consistently wrapped at 40-80 bases. The tool `NormalizeFasta` can help to reformat fasta data correctly in most cases and the final formatting is the same as that of a custom genome.

2. The **sample names** are exactly the same between the form entry/list and the VCF content. This is a file that you create/upload to Galaxy or by using the `Upload` tool’s “paste” function (use the gear icon option to “convert spaces to tabs” to ensure proper tabular formatting).

Some help links:

- [Format help for Tabular/BED/Interval Datasets](https://galaxyproject.org/support/tabular/)
- [Common datatypes explained](https://galaxyproject.org/learn/datatypes/)
- [The tool I’m using does not recognize any input datasets. Why?](https://galaxyproject.org/support/datatypes-and-tools/)
- [How do I find, adjust, and/or correct metadata?](https://galaxyproject.org/support/metadata/)
- [Preparing and using a Custom Reference Genome or Build](https://galaxyproject.org/learn/custom-genomes/)
- [Mismatched Chromosome identifiers (and how to avoid them)](https://galaxyproject.org/support/chrom-identifiers/)

Hope this works out!
