Examples of DP()


Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        // create the single Genotype with GQ and DP annotations
        final GenotypeBuilder gb = new GenotypeBuilder(sampleName, GATKVariantContextUtils.homozygousAlleleList(block.getRef(),block.getPloidy()));
        gb.noAD().noPL().noAttributes(); // clear all attributes
        gb.GQ(block.getMedianGQ());
        gb.DP(block.getMedianDP());
        gb.attribute(MIN_DP_FORMAT_FIELD, block.getMinDP());
        gb.PL(block.getMinPLs());

        // This annotation is no longer standard
        //gb.attribute(MIN_GQ_FORMAT_FIELD, block.getMinGQ());
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        final HomRefBlock band = new HomRefBlock(vc, 10, 20, HomoSapiensConstants.DEFAULT_PLOIDY);
        final GenotypeBuilder gb = new GenotypeBuilder("NA12878");
        gb.alleles(vc.getAlleles());

        int pos = vc.getStart();
        band.add(pos++, gb.DP(10).GQ(11).PL(new int[]{0,11,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 10, 11, 11);

        band.add(pos++, gb.DP(11).GQ(10).PL(new int[]{0,10,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        int pos = vc.getStart();
        band.add(pos++, gb.DP(10).GQ(11).PL(new int[]{0,11,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 10, 11, 11);

        band.add(pos++, gb.DP(11).GQ(10).PL(new int[]{0,10,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 11, 10, 11);

        band.add(pos++, gb.DP(12).GQ(12).PL(new int[]{0,12,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        band.add(pos++, gb.DP(11).GQ(10).PL(new int[]{0,10,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 11, 10, 11);

        band.add(pos++, gb.DP(12).GQ(12).PL(new int[]{0,12,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 11, 10, 11);

        band.add(pos++, gb.DP(13).GQ(15).PL(new int[]{0,15,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        band.add(pos++, gb.DP(12).GQ(12).PL(new int[]{0,12,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 11, 10, 11);

        band.add(pos++, gb.DP(13).GQ(15).PL(new int[]{0,15,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(14).GQ(16).PL(new int[]{0,16,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(15).GQ(17).PL(new int[]{0,17,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 11, 10, 11);

        band.add(pos++, gb.DP(13).GQ(15).PL(new int[]{0,15,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(14).GQ(16).PL(new int[]{0,16,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(15).GQ(17).PL(new int[]{0,17,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(16).GQ(18).PL(new int[]{0,18,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        band.add(pos++, gb.DP(13).GQ(15).PL(new int[]{0,15,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(14).GQ(16).PL(new int[]{0,16,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(15).GQ(17).PL(new int[]{0,17,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(16).GQ(18).PL(new int[]{0,18,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 13, 10, 15);
        Assert.assertEquals(band.getSize(), pos - vc.getStart());
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(14).GQ(16).PL(new int[]{0,16,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(15).GQ(17).PL(new int[]{0,17,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        band.add(pos++, gb.DP(16).GQ(18).PL(new int[]{0,18,100}).make());
        Assert.assertEquals(band.getStop(), pos - 1);
        assertValues(band, 10, 13, 10, 15);
        Assert.assertEquals(band.getSize(), pos - vc.getStart());
        Assert.assertTrue(Arrays.equals(band.getMinPLs(), new int[]{0,10,100}));
    }
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

    public void testBigGQIsCapped() {
        final HomRefBlock band = new HomRefBlock(vc, 10, 20, HomoSapiensConstants.DEFAULT_PLOIDY);
        final GenotypeBuilder gb = new GenotypeBuilder("NA12878");
        gb.alleles(vc.getAlleles());

        band.add(vc.getStart(), gb.DP(1000).GQ(1000).PL(new int[]{0,10,100}).make());
        assertValues(band, 1000, 1000, 99, 99);
    }

    @Test(expectedExceptions = IllegalArgumentException.class)
    public void testBadAdd() {
View Full Code Here

Examples of htsjdk.variant.variantcontext.GenotypeBuilder.DP()

    @Test(expectedExceptions = IllegalArgumentException.class)
    public void testBadAdd() {
        final HomRefBlock band = new HomRefBlock(vc, 10, 20, HomoSapiensConstants.DEFAULT_PLOIDY);
        final GenotypeBuilder gb = new GenotypeBuilder("NA12878");

        band.add(vc.getStart() + 10, gb.DP(10).GQ(11).PL(new int[]{0,10,100}).make());
    }

    private void assertValues(final HomRefBlock band, final int minDP, final int medianDP, final int minGQ, final int medianGQ) {
        Assert.assertEquals(band.getMinDP(), minDP);
        Assert.assertEquals(band.getMedianDP(), medianDP);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.