Documentation of 'org.statcato.statistics.inferential.CrossTabulation' Java class
CrossTabulation
org.statcato.statistics.inferential

Class CrossTabulation



  • public class CrossTabulation
    extends java.lang.Object
    Cross tabulation and Chi-square test.
    Since:
    1.0
    See Also:
    ContingencyTable
    • Constructor Summary

      Constructors 
      Constructor and Description
      CrossTabulation(int a, int b)
      Constructor, given the number of rows and columns.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void addObservation(int i, int j, double frequency)
      Adds the given frequency to the location at row i and column j.
      void computeChiSquare()
      Creates a contingency table object using the cross tabulation data.
      double getColumnSum(int j)
      Return the sum of the given column.
      double getColumnSumPercent(int i)
      Return the percent of the sum of the given column out of the total sum.
      ContingencyTable getContingencyTable()
      Returns the contingency table.
      double getFrequency(int i, int j)
      Returns the frequency at row i and column j.
      double getPercent(int i, int j)
      Returns the percent at row i and column j.
      double getRowSum(int i)
      Return the sum of the given row.
      double getRowSumPercent(int i)
      Return the percent of the sum of the given row out of the total sum.
      double getTotalSum()
      Return the total sum.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CrossTabulation

        public CrossTabulation(int a,
                               int b)
        Constructor, given the number of rows and columns.
        Parameters:
        a - number of rows
        b - number of columns
    • Method Detail

      • addObservation

        public void addObservation(int i,
                                   int j,
                                   double frequency)
        Adds the given frequency to the location at row i and column j.
        Parameters:
        i - row index
        j - column index
        data - double array
      • getFrequency

        public double getFrequency(int i,
                                   int j)
        Returns the frequency at row i and column j.
        Parameters:
        i - row index
        j - column index
        Returns:
        frequency
      • getPercent

        public double getPercent(int i,
                                 int j)
        Returns the percent at row i and column j.
        Parameters:
        i -
        j -
        Returns:
        percent
      • getRowSum

        public double getRowSum(int i)
        Return the sum of the given row.
        Parameters:
        i - row index
        Returns:
        row sum
      • getRowSumPercent

        public double getRowSumPercent(int i)
        Return the percent of the sum of the given row out of the total sum.
        Parameters:
        i - row index
        Returns:
        row sum percent
      • getColumnSum

        public double getColumnSum(int j)
        Return the sum of the given column.
        Parameters:
        j - column index
        Returns:
        column sum
      • getColumnSumPercent

        public double getColumnSumPercent(int i)
        Return the percent of the sum of the given column out of the total sum.
        Parameters:
        i - column index
        Returns:
        column sum percent
      • getTotalSum

        public double getTotalSum()
        Return the total sum.
        Returns:
        total sum
      • computeChiSquare

        public void computeChiSquare()
        Creates a contingency table object using the cross tabulation data.
      • getContingencyTable

        public ContingencyTable getContingencyTable()
        Returns the contingency table.
        Returns:
        ContingencyTable object

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.