@Test public void testTestVariance() { logger.info("testVariance"); double stdbar = 0.0063; int n = 100; double H0std = 0.01; boolean is_twoTailed = true; double aLevel = 0.05; boolean expResult = true; boolean result = ChisquareOneSample.testVariance(stdbar, n, H0std, is_twoTailed, aLevel); assertEquals(expResult, result); }
public static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel) { if(n<=1 || H0std<=0) { throw new IllegalArgumentException("The values of the provided parameters are not within the permitted range."); } double chisquare=(n-1.0)*stdbar*stdbar/(H0std*H0std); boolean rejectH0=checkCriticalValue(chisquare, n, is_twoTailed, aLevel); return rejectH0; }
ChisquareOneSample { public static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel) { if(n<=1 || H0std<=0) { throw new IllegalArgumentException("The values of the provided parameters are not within the permitted range."); } double chisquare=(n-1.0)*stdbar*stdbar/(H0std*H0std); boolean rejectH0=checkCriticalValue(chisquare, n, is_twoTailed, aLevel); return rejectH0; } }
ChisquareOneSample { public static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel) { if(n<=1 || H0std<=0) { throw new IllegalArgumentException("The values of the provided parameters are not within the permitted range."); } double chisquare=(n-1.0)*stdbar*stdbar/(H0std*H0std); boolean rejectH0=checkCriticalValue(chisquare, n, is_twoTailed, aLevel); return rejectH0; }  }
ChisquareOneSample { public static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel) { if(n<=1 || H0std<=0) { throw new IllegalArgumentException("The values of the provided parameters are not within the permitted range."); } double chisquare=(n-1.0)*stdbar*stdbar/(H0std*H0std); boolean rejectH0=checkCriticalValue(chisquare, n, is_twoTailed, aLevel); return rejectH0; }  static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel); }
ChisquareOneSample { public static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel) { if(n<=1 || H0std<=0) { throw new IllegalArgumentException("The values of the provided parameters are not within the permitted range."); } double chisquare=(n-1.0)*stdbar*stdbar/(H0std*H0std); boolean rejectH0=checkCriticalValue(chisquare, n, is_twoTailed, aLevel); return rejectH0; }  static boolean testVariance(double stdbar, int n, double H0std, boolean is_twoTailed, double aLevel);  }