Home
last modified time | relevance | path

Searched refs:chi_square (Results 1 – 25 of 31) sorted by relevance

12

/third_party/skia/third_party/externals/abseil-cpp/absl/random/internal/
Dchi_square.h43 double chi_square = 0; in ChiSquareWithExpected() local
46 chi_square += d * d; in ChiSquareWithExpected()
48 chi_square = chi_square / expected; in ChiSquareWithExpected()
49 return chi_square; in ChiSquareWithExpected()
57 double chi_square = 0; in ChiSquare() local
66 chi_square += (d * d) / e; in ChiSquare()
70 return chi_square; in ChiSquare()
83 double ChiSquarePValue(double chi_square, int dof);
Dchi_square_test.cc37 double chi_square; in TEST() member
95 const double err = std::max(5e-6, spec.chi_square / 5e3); // 1 part in 5000 in TEST()
96 EXPECT_NEAR(spec.chi_square, val, err) << spec.line; in TEST()
117 double chi_square; in TEST() member
137 const double pval = ChiSquarePValue(spec.chi_square, spec.df); in TEST()
162 double chi_square = 0; in TEST() local
165 chi_square += (diff * diff) / spec.expected[i]; in TEST()
167 EXPECT_NEAR(chi_square, in TEST()
326 double chi_square = ChiSquare(std::begin(counts), std::end(counts), in TEST() local
328 EXPECT_NEAR(chi_square, 2.69, 0.001); in TEST()
[all …]
Dchi_square.cc156 double ChiSquarePValue(double chi_square, int dof) { in ChiSquarePValue() argument
170 const double chi_square_scaled = std::pow(chi_square / dof, 1.0 / 3); in ChiSquarePValue()
188 if (chi_square <= 0.0) return 1.0; in ChiSquarePValue()
198 double a = 0.5 * chi_square; in ChiSquarePValue()
201 double s = even ? y : (2.0 * POZ(-std::sqrt(chi_square))); in ChiSquarePValue()
207 chi_square = 0.5 * (dof - 1.0); in ChiSquarePValue()
212 while (z <= chi_square) { in ChiSquarePValue()
222 while (z <= chi_square) { in ChiSquarePValue()
/third_party/abseil-cpp/absl/random/internal/
Dchi_square.h43 double chi_square = 0; in ChiSquareWithExpected() local
46 chi_square += d * d; in ChiSquareWithExpected()
48 chi_square = chi_square / expected; in ChiSquareWithExpected()
49 return chi_square; in ChiSquareWithExpected()
57 double chi_square = 0; in ChiSquare() local
66 chi_square += (d * d) / e; in ChiSquare()
70 return chi_square; in ChiSquare()
83 double ChiSquarePValue(double chi_square, int dof);
Dchi_square_test.cc37 double chi_square; in TEST() member
95 const double err = std::max(5e-6, spec.chi_square / 5e3); // 1 part in 5000 in TEST()
96 EXPECT_NEAR(spec.chi_square, val, err) << spec.line; in TEST()
117 double chi_square; in TEST() member
137 const double pval = ChiSquarePValue(spec.chi_square, spec.df); in TEST()
162 double chi_square = 0; in TEST() local
165 chi_square += (diff * diff) / spec.expected[i]; in TEST()
167 EXPECT_NEAR(chi_square, in TEST()
326 double chi_square = ChiSquare(std::begin(counts), std::end(counts), in TEST() local
328 EXPECT_NEAR(chi_square, 2.69, 0.001); in TEST()
[all …]
Dchi_square.cc156 double ChiSquarePValue(double chi_square, int dof) { in ChiSquarePValue() argument
170 const double chi_square_scaled = std::pow(chi_square / dof, 1.0 / 3); in ChiSquarePValue()
188 if (chi_square <= 0.0) return 1.0; in ChiSquarePValue()
198 double a = 0.5 * chi_square; in ChiSquarePValue()
201 double s = even ? y : (2.0 * POZ(-std::sqrt(chi_square))); in ChiSquarePValue()
207 chi_square = 0.5 * (dof - 1.0); in ChiSquarePValue()
212 while (z <= chi_square) { in ChiSquarePValue()
222 while (z <= chi_square) { in ChiSquarePValue()
/third_party/boost/boost/math/distributions/
Dchi_squared.hpp89 RealType pdf(const chi_squared_distribution<RealType, Policy>& dist, const RealType& chi_square) in pdf() argument
102 if((chi_square < 0) || !(boost::math::isfinite)(chi_square)) in pdf()
105 function, "Chi Square parameter was %1%, but must be > 0 !", chi_square, Policy()); in pdf()
108 if(chi_square == 0) in pdf()
126 return gamma_p_derivative(degrees_of_freedom / 2, chi_square / 2, Policy()) / 2; in pdf()
130 …ne RealType cdf(const chi_squared_distribution<RealType, Policy>& dist, const RealType& chi_square) in cdf() argument
141 if((chi_square < 0) || !(boost::math::isfinite)(chi_square)) in cdf()
144 function, "Chi Square parameter was %1%, but must be > 0 !", chi_square, Policy()); in cdf()
147 return boost::math::gamma_p(degrees_of_freedom / 2, chi_square / 2, Policy()); in cdf()
171 RealType const& chi_square = c.param; in cdf() local
[all …]
/third_party/skia/third_party/externals/abseil-cpp/absl/random/
Ddiscrete_distribution_test.cc181 double chi_square = in TEST() local
185 if (chi_square > kThreshold) { in TEST()
187 absl::random_internal::ChiSquarePValue(chi_square, kBuckets); in TEST()
195 absl::StrAppend(&msg, "High ", kChiSquared, " value: ", chi_square, " > ", in TEST()
Dlog_uniform_int_distribution_test.cc179 double chi_square = absl::random_internal::ChiSquareWithExpected( in ChiSquaredTestImpl() local
182 const double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in ChiSquaredTestImpl()
184 if (chi_square > threshold) { in ChiSquaredTestImpl()
193 trials, kChiSquared, dof, chi_square, p, in ChiSquaredTestImpl()
Duniform_int_distribution_test.cc198 double chi_square = absl::random_internal::ChiSquareWithExpected( in TYPED_TEST() local
200 if (chi_square > kThreshold) { in TYPED_TEST()
202 absl::random_internal::ChiSquarePValue(chi_square, kBuckets); in TYPED_TEST()
210 absl::StrAppend(&msg, "High ", kChiSquared, " value: ", chi_square, " > ", in TYPED_TEST()
Dzipf_distribution_test.cc297 const double chi_square = absl::random_internal::ChiSquare( in TEST_P() local
302 absl::random_internal::ChiSquarePValue(chi_square, dof); in TEST_P()
305 if (chi_square > threshold) { in TEST_P()
315 chi_square, " (", p_actual, ")")); in TEST_P()
318 FAIL() << kChiSquared << " value of " << chi_square in TEST_P()
Duniform_real_distribution_test.cc279 double chi_square = absl::random_internal::ChiSquareWithExpected( in TYPED_TEST() local
281 if (chi_square > kThreshold) { in TYPED_TEST()
283 absl::random_internal::ChiSquarePValue(chi_square, kBuckets); in TYPED_TEST()
291 absl::StrAppend(&msg, "High ", kChiSquared, " value: ", chi_square, " > ", in TYPED_TEST()
Dexponential_distribution_test.cc272 double chi_square = absl::random_internal::ChiSquareWithExpected( in SingleChiSquaredTest() local
274 double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in SingleChiSquaredTest()
276 if (chi_square > threshold) { in SingleChiSquaredTest()
285 kChiSquared, " ", chi_square, " (", p, ")\n", in SingleChiSquaredTest()
Dgaussian_distribution_test.cc294 double chi_square = absl::random_internal::ChiSquareWithExpected( in SingleChiSquaredTest() local
296 double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in SingleChiSquaredTest()
299 if (chi_square > threshold) { in SingleChiSquaredTest()
308 kChiSquared, " ", chi_square, " (", p, ")\n", // in SingleChiSquaredTest()
Dpoisson_distribution_test.cc433 const double chi_square = absl::random_internal::ChiSquare( in ChiSquaredTestImpl() local
436 const double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in ChiSquaredTestImpl()
439 if (chi_square > threshold) { in ChiSquaredTestImpl()
451 absl::StrCat(kChiSquared, "(data, dof=", dof, ") = ", chi_square, " (", in ChiSquaredTestImpl()
Dbeta_distribution_test.cc384 const double chi_square = absl::random_internal::ChiSquare( in SingleChiSquaredTest() local
387 (absl::random_internal::ChiSquarePValue(chi_square, dof) >= p); in SingleChiSquaredTest()
399 absl::random_internal::kChiSquared, chi_square, in SingleChiSquaredTest()
400 absl::random_internal::ChiSquarePValue(chi_square, dof))); in SingleChiSquaredTest()
/third_party/abseil-cpp/absl/random/
Ddiscrete_distribution_test.cc180 double chi_square = in TEST() local
184 if (chi_square > kThreshold) { in TEST()
186 absl::random_internal::ChiSquarePValue(chi_square, kBuckets); in TEST()
194 absl::StrAppend(&msg, "High ", kChiSquared, " value: ", chi_square, " > ", in TEST()
Dlog_uniform_int_distribution_test.cc179 double chi_square = absl::random_internal::ChiSquareWithExpected( in ChiSquaredTestImpl() local
182 const double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in ChiSquaredTestImpl()
184 if (chi_square > threshold) { in ChiSquaredTestImpl()
193 trials, kChiSquared, dof, chi_square, p, in ChiSquaredTestImpl()
Duniform_int_distribution_test.cc198 double chi_square = absl::random_internal::ChiSquareWithExpected( in TYPED_TEST() local
200 if (chi_square > kThreshold) { in TYPED_TEST()
202 absl::random_internal::ChiSquarePValue(chi_square, kBuckets); in TYPED_TEST()
210 absl::StrAppend(&msg, "High ", kChiSquared, " value: ", chi_square, " > ", in TYPED_TEST()
Duniform_real_distribution_test.cc264 double chi_square = absl::random_internal::ChiSquareWithExpected( in TYPED_TEST() local
266 if (chi_square > kThreshold) { in TYPED_TEST()
268 absl::random_internal::ChiSquarePValue(chi_square, kBuckets); in TYPED_TEST()
276 absl::StrAppend(&msg, "High ", kChiSquared, " value: ", chi_square, " > ", in TYPED_TEST()
Dzipf_distribution_test.cc297 const double chi_square = absl::random_internal::ChiSquare( in TEST_P() local
302 absl::random_internal::ChiSquarePValue(chi_square, dof); in TEST_P()
305 if (chi_square > threshold) { in TEST_P()
315 chi_square, " (", p_actual, ")")); in TEST_P()
318 FAIL() << kChiSquared << " value of " << chi_square in TEST_P()
Dexponential_distribution_test.cc283 double chi_square = absl::random_internal::ChiSquareWithExpected( in SingleChiSquaredTest() local
285 double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in SingleChiSquaredTest()
287 if (chi_square > threshold) { in SingleChiSquaredTest()
296 kChiSquared, " ", chi_square, " (", p, ")\n", in SingleChiSquaredTest()
Dpoisson_distribution_test.cc433 const double chi_square = absl::random_internal::ChiSquare( in ChiSquaredTestImpl() local
436 const double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in ChiSquaredTestImpl()
439 if (chi_square > threshold) { in ChiSquaredTestImpl()
451 absl::StrCat(kChiSquared, "(data, dof=", dof, ") = ", chi_square, " (", in ChiSquaredTestImpl()
Dgaussian_distribution_test.cc310 double chi_square = absl::random_internal::ChiSquareWithExpected( in SingleChiSquaredTest() local
312 double p = absl::random_internal::ChiSquarePValue(chi_square, dof); in SingleChiSquaredTest()
315 if (chi_square > threshold) { in SingleChiSquaredTest()
324 kChiSquared, " ", chi_square, " (", p, ")\n", // in SingleChiSquaredTest()
Dbeta_distribution_test.cc401 const double chi_square = absl::random_internal::ChiSquare( in SingleChiSquaredTest() local
404 (absl::random_internal::ChiSquarePValue(chi_square, dof) >= p); in SingleChiSquaredTest()
416 absl::random_internal::kChiSquared, chi_square, in SingleChiSquaredTest()
417 absl::random_internal::ChiSquarePValue(chi_square, dof))); in SingleChiSquaredTest()

12