Print nicely formatted version of an diffdf object
Usage
# S3 method for diffdf
print(x, ..., as_string = FALSE)
Arguments
- x
comparison object created by diffdf().
- ...
Additional arguments (not used)
- as_string
Return printed message as an R character vector?
Examples
x <- subset( iris , -Species )
#> Warning: ‘-’ not meaningful for factors
x[1,2] <- 5
COMPARE <- diffdf( iris, x)
#> Warning:
#> There are rows in BASE that are not in COMPARE !!
#> Not all Values Compared Equal
print( COMPARE )
#> Differences found between the objects!
#>
#> A summary is given below.
#>
#> There are rows in BASE that are not in COMPARE !!
#> First 10 of 149 rows are shown in table below
#>
#> ===============
#> ..ROWNUMBER..
#> ---------------
#> 2
#> 3
#> 4
#> 5
#> 6
#> 7
#> 8
#> 9
#> 10
#> 11
#> ---------------
#>
#> Not all Values Compared Equal
#> All rows are shown in table below
#>
#> =================================
#> Variable No of Differences
#> ---------------------------------
#> Sepal.Length 1
#> Sepal.Width 1
#> Petal.Length 1
#> Petal.Width 1
#> Species 1
#> ---------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ============================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> --------------------------------------------
#> Sepal.Length 1 5.1 <NA>
#> --------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ===========================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> -------------------------------------------
#> Sepal.Width 1 3.5 5
#> -------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ============================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> --------------------------------------------
#> Petal.Length 1 1.4 <NA>
#> --------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ===========================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> -------------------------------------------
#> Petal.Width 1 0.2 <NA>
#> -------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ==========================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> ------------------------------------------
#> Species 1 setosa <NA>
#> ------------------------------------------
#>
print( COMPARE , "Sepal.Length" )
#> Differences found between the objects!
#>
#> A summary is given below.
#>
#> There are rows in BASE that are not in COMPARE !!
#> First 10 of 149 rows are shown in table below
#>
#> ===============
#> ..ROWNUMBER..
#> ---------------
#> 2
#> 3
#> 4
#> 5
#> 6
#> 7
#> 8
#> 9
#> 10
#> 11
#> ---------------
#>
#> Not all Values Compared Equal
#> All rows are shown in table below
#>
#> =================================
#> Variable No of Differences
#> ---------------------------------
#> Sepal.Length 1
#> Sepal.Width 1
#> Petal.Length 1
#> Petal.Width 1
#> Species 1
#> ---------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ============================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> --------------------------------------------
#> Sepal.Length 1 5.1 <NA>
#> --------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ===========================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> -------------------------------------------
#> Sepal.Width 1 3.5 5
#> -------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ============================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> --------------------------------------------
#> Petal.Length 1 1.4 <NA>
#> --------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ===========================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> -------------------------------------------
#> Petal.Width 1 0.2 <NA>
#> -------------------------------------------
#>
#>
#> All rows are shown in table below
#>
#> ==========================================
#> VARIABLE ..ROWNUMBER.. BASE COMPARE
#> ------------------------------------------
#> Species 1 setosa <NA>
#> ------------------------------------------
#>