A simple plugin to open VCF and BCF files in Visidata using pysam to parse the files.
mkdir -p ~/.visidata/plugins
- Download the plugin to the directory creted:
wget -P ~/.visidata/plugins https://raw.githubusercontent.com/rafaeltou/VdCallFormat/refs/heads/main/VdCallFormat.py
- Add the plugin to ~/.visidatarc:
echo "import plugins.VdCallFormat" >> ~/.visidatarc
The usage is very simple. Once installed, you just point the Visidata to the vcf(.gz)/bcf file, eg:
vd file.vcf
--threads=number:
for the number of threads used in the file parsing in cyvcf2. In my tests it doesn't make much difference. the standard value is 4.
--region=chr:posBegin-posEnd:
for specifying the region you want to see. You can use --region=chr:posBegin to see a single position and --region=chr to see an entire chromossome. This option requires your variant file to be indexed, otherwise it will fail. I recommend always using this option if your file is too big, since the visidata will load all of it to the computer's RAM.
Developed by Rafael Tou (@rafaeltou)