Package vcf

Class VcfRecGTParser.HapListRep

  • Enclosing class:
    VcfRecGTParser

    public static class VcfRecGTParser.HapListRep
    extends java.lang.Object
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int[][] hapLists​(boolean setMajorToNull)
      Returns an array of length this.marker().nAlleles() that contains lists of haplotypes carrying each allele.
      boolean isPhased()
      Returns true if all genotypes are phased and there are no missing alleles, and returns false otherwise.
      int majorAllele()
      Returns the major allele.
      Marker marker()
      Returns the marker.
      int[] missingSamples()
      Returns a list of samples with missing indices
      int nonmajorAlleleCnt()
      Returns the non-major allele count.
      Samples samples()
      Returns the samples.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • nonmajorAlleleCnt

        public int nonmajorAlleleCnt()
        Returns the non-major allele count.
        Returns:
        the non-major allele count
      • missingSamples

        public int[] missingSamples()
        Returns a list of samples with missing indices
        Returns:
        a list of samples with missing indices
      • majorAllele

        public int majorAllele()
        Returns the major allele. The major allele is the allele with largest number of copies. If there are multiple major alleles the major allele with smallest index is returned.
        Returns:
        the major allele
      • hapLists

        public int[][] hapLists​(boolean setMajorToNull)
        Returns an array of length this.marker().nAlleles() that contains lists of haplotypes carrying each allele. The increasing list of haplotype indices carrying non-major allele j is stored in the j-th element of the returned array. if (@code setMajorToNull == true} then element of the returned array corresponding to this.majorAllele() will be null
        Parameters:
        setMajorToNull - true if the element of the returned array corresponding to this.majorAllele() will be null
        Returns:
        list of haplotypes carrying each allele.
      • marker

        public Marker marker()
        Returns the marker.
        Returns:
        the marker
      • samples

        public Samples samples()
        Returns the samples.
        Returns:
        the samples
      • isPhased

        public boolean isPhased()
        Returns true if all genotypes are phased and there are no missing alleles, and returns false otherwise.
        Returns:
        true if all genotypes are phased and nonomissing