tests/testthat/test-loudness.R

test_that("Loudness Engine - ISO 226 Anchor and Power Law Validation", {
  skip_if_not(exists("calculate_loudness", mode="function"))
  # Note: A real loudness validation would check the physics bounds.
  # Based on Moore & Glasberg (2004), we allow a ~8% tolerance for power law tests
  # ISO Anchor: 1 kHz at 40 dB SPL should be exactly 1.0 sones.
  # 50 dB SPL should be ~2.0 sones.
  
  expect_true(TRUE) # Placeholder for the loudness engine tests
})

Try the SII package in your browser

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

SII documentation built on Sept. 12, 2026, 5:08 p.m.