This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Convert BCF to BAM

Hiii, I want to know the command line to convert BCF to BAM file on terminal (Linux). Kindly help me out. Thanks in advance

bcf to bam linux ubuntu terminal command line

converting a bcf to a bam is like creating a cow from a steak.

Thanks a lot for your help. Now i have VCF file and i have downloaded jvarkit-master. Now when i am downloading and compiling dependencies i am getting error when i run this command ./gradlew vcf2bam. The error is FAILURE: Build failed with an exception.

What went wrong: Could not create an instance of type org.gradle.initialization.DefaultSettings_Decorated.

    Could not initialize class org.codehaus.groovy.runtime.InvokerHelper

Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

Get more help at https://help.gradle.org

BUILD FAILED in 0s

Will you please help me to resolve it ? Thanks

I am getting the same error. I have tried all possible options ./gradlew --stacktrace vcf2bam ./gradlew --scan vcf2bam ./gradlew --debug vcf2bam ./gradlew --info vcf2bam

I am really sorry to trouble you again and again

Ubuntu (Linux OS). Secondly i have put my jvarkit-master in java 11 folder and has given path to it.

and there is no stacktrace ? only this message " Could not initialize class org.codehaus.groovy.runtime.InvokerHelper" ?

when i run this command ./gradlew --stacktrace vcf2bam the error occurs is FAILURE: Build failed with an exception.

  • What went wrong: Could not create an instance of type org.gradle.initialization.DefaultSettings_Decorated.

    Could not initialize class org.codehaus.groovy.runtime.InvokerHelper

  • Try: Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Exception is: org.gradle.api.reflect.ObjectInstantiationException: Could not create an instance of type org.gradle.initialization.DefaultSettings_Decorated. . . . . .

    Caused by: java.lang.NoClassDefFoundError: Could not initialize class org.codehaus.groovy.runtime.InvokerHelper at org.gradle.api.internal.plugins.DefaultExtraPropertiesExtension.<init>(DefaultExtraPropertiesExtension.java:29) at org.gradle.api.internal.plugins.DefaultConvention.<init>(DefaultConvention.java:47) at org.gradle.api.internal.ExtensibleDynamicObject.<init>(ExtensibleDynamicObject.java:58) at org.gradle.initialization.DefaultSettings.<init>(DefaultSettings.java:93) at org.gradle.initialization.DefaultSettings_Decorated.<init>(Unknown Source) at jdk.internal.reflect.GeneratedConstructorAccessor10.newInstance(Unknown Source) at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at org.gradle.internal.reflect.DirectInstantiator.newInstance(DirectInstantiator.java:51) ... 100 more

hum sorry, no idea how to fix this. Try to compile this on another computer ?

Sure i will try and thank you so much for your kind and quick responses @Pierre Lindenbaum.

Thanks a lot for your help. Now i have VCF file and i have downloaded jvarkit-master. Now when i am downloading and compiling dependencies i am getting error when i run this command ./gradlew vcf2bam. The error is FAILURE: Build failed with an exception.

  • What went wrong: Could not create an instance of type org.gradle.initialization.DefaultSettings_Decorated.

    Could not initialize class org.codehaus.groovy.runtime.InvokerHelper

  • Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 0s

Will you please help me to resolve it ? Thanks

I had a question about the reference file format for the vcf2bam tool. I know how to index a fasta file and how to make a sequence dictionary, but I keep getting errors for trying to do both. How do you generate the correct reference file?

1 answer

i wrote a vcf2bam. http://lindenb.github.io/jvarkit/VcfToBam.html

I hardly ever used it.

you have to first convert the bcf to vcf with bcftools view

Log in to answer this question.