tests/testthat/test_simple.cc.R

test_that('-1.', {

  s1 = c(0, 1)
  s2 = c(1)
  scc = simple.cc(s1, s2)

  expect_equal(scc, -1)

})

test_that('Normalise.', {

  s1 = c(0, 1, 2)
  s2 = c(1, 2)
  scc = simple.cc(s1, s2, norm = T)

  expect_equal(scc, -1/3)

})

Try the callsync package in your browser

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

callsync documentation built on May 29, 2024, 5:30 a.m.