Class MannWhitneyUTest.Result

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private boolean tiedValues
      Flag indicating the data has tied values.
    • Constructor Summary

      Constructors 
      Constructor Description
      Result​(double statistic, boolean tiedValues, double p)
      Create an instance.
    • Field Detail

      • tiedValues

        private final boolean tiedValues
        Flag indicating the data has tied values.
    • Constructor Detail

      • Result

        Result​(double statistic,
               boolean tiedValues,
               double p)
        Create an instance.
        Parameters:
        statistic - Test statistic.
        tiedValues - Flag indicating the data has tied values.
        p - Result p-value.
    • Method Detail

      • getStatistic

        public double getStatistic()
        Returns the test statistic.

        This is the U1 statistic. Compute the U2 statistic using the original sample lengths n and m using:

         u2 = (long) n * m - u1;
         
        Specified by:
        getStatistic in interface SignificanceResult
        Overrides:
        getStatistic in class BaseSignificanceResult
        Returns:
        the statistic
      • hasTiedValues

        public boolean hasTiedValues()
        Return true if the data had tied values.

        Note: The exact computation cannot be used when there are tied values.

        Returns:
        true if there were tied values