tests/testthat/test-convergence.r

EPS <- sqrt(.Machine$double.eps)

test_that("rfit convergence", {
  x<-y<-rep(0:1,each=10)
  err<-rfit(y~x)$coef[2]-1
  expect_less_than(err,EPS)
})

Try the Rfit package in your browser

Any scripts or data that you put into this service are public.

Rfit documentation built on May 29, 2024, 11:38 a.m.