tests/testthat/test-calcHistMatch.R

# devtools::test(".", "calcHistMatch")
context("calcHistMatch")


#-------------------------------------------------------------------------------
test_that("calcHistMatch for raster works as expected", {
  path <- system.file("extdata", package = "satellite")
  
  files <- list.files(path, pattern = glob2rx("LE7*.TIF"), full.names = TRUE)
  l7 <- satellite(files)
  
  files <- list.files(path, pattern = glob2rx("LC8*.TIF"), full.names = TRUE)
  l8 <- satellite(files)
  
  x <- getSatDataLayer(l7, "B002n")
  target <- getSatDataLayer(l8, "B003n")

#   Rsenal::histmatchRaster(x, target)
  
  
  })
environmentalinformatics-marburg/satelliteTools documentation built on May 16, 2019, 8:16 a.m.