Validating Data for Interpolation — ar_validate • areal
Description: ar_validate executes a series of logic tests for sf object status, shared coordinates between source and target data, appropriate project, and absence of variable name conflicts.

# Validating Data for Interpolation

Source: `R/ar_validate.R`
`ar_validate.Rd`

`ar_validate` executes a series of logic tests for `sf` object status, shared coordinates between source and target data, appropriate project, and absence of variable name conflicts.

    ar_validate(source, target, varList, method = "aw", verbose = FALSE)

## Arguments

source | A `sf` object with data to be interpolated
target | A `sf` object that data should be interpolated to
varList | A vector of variable names to be added to the `target` object
method | The areal interpolation method validation is being performed for. This should be set to `"aw"`. Additional functionality will be added as the package adds new interpolation techniques.
verbose | A logical scalar; if `TRUE`, a tibble with test results is returned

## Value

If `verbose` is `FALSE`, a logical scalar is returned that is `TRUE` is all tests are passed and `FALSE` if one or more tests is failed. If `verbose` is `TRUE`, a tibble with detailed test results is returned.

## See also

c

## Examples

    ar_validate(source = ar_stl_asthma, target = ar_stl_wards, varList = "ASTHMA")#> [1] TRUE
    ar_validate(source = ar_stl_asthma, target = ar_stl_wards, varList = "ASTHMA", verbose = TRUE)#> # A tibble: 6 x 2
    #>   test                            result
    #>   <chr>                           <lgl>
    #> 1 sf Objects                      TRUE
    #> 2 CRS Match                       TRUE
    #> 3 CRS is Planar                   TRUE
    #> 4 Variables Exist in Source       TRUE
    #> 5 No Variable Conflicts in Target TRUE
    #> 6 Overall Evaluation              TRUE