Showing 2 of 4 files from the diff.
Newly tracked file
R/mesh_pal.R created.
Other files ignored by Codecov
NAMESPACE has changed.
DESCRIPTION has changed.

@@ -0,0 +1,37 @@
Loading
1 +
.quad_to_edge <- function(x) {
2 +
  if (is.null(x)) return(NULL)
3 +
  cbind(x[1:2, ], x[2:3, ], x[c(3, 1)])
4 +
}
5 +
.tri_to_edge <- function(x) {
6 +
  if (is.null(x)) return(NULL)
7 +
  cbind(x[1:2, ], x[2:3, ], x[3:4, ], x[c(4, 1), ])
8 +
9 +
}
10 +
11 +
mesh_pal <- function(x, col, ..., meshColor = NULL, pal_dim = 3L)  {
12 +
  if (missing(col)) {
13 +
    col <- hcl.colors(24)
14 +
  }
15 +
  if (is.null(meshColor)) {
16 +
    meshColor <- x$meshColor
17 +
  }
18 +
  scl <- function(x) {
19 +
    x <- c(x)
20 +
    x <- x[!is.na(x)]
21 +
    (x - min(x))/diff(range(x))
22 +
  }
23 +
24 +
  idx <- TRUE
25 +
  if (meshColor == "faces") {
26 +
    idx <- c(x$it, x$ib)
27 +
    out <- col[1 + scl(x$vb[pal_dim, idx]) * length(col)]
28 +
29 +
  }
30 +
  if (meshColor == "edges") {
31 +
    idx <- c(.tri_to_edge(x$it), .quad_to_edge(x$ib))
32 +
33 +
    out <- col[1 + scl(colMeans(matrix(x$vb[pal_dim, idx], 2))) * length(col)]
34 +
  }
35 +
  ## else vertices
36 +
  out
37 +
}

@@ -24,6 +24,7 @@
Loading
24 24
#' @export
25 25
#' @aliases image_raster image_stars
26 26
#' @export
27 +
#' @importFrom grDevices hcl.colors
27 28
#' @examples
28 29
#' set.seed(28)
29 30
#' vals <- sort(rnorm(100))
Files Coverage
R 94.33%
Project Totals (6 files) 94.33%
1
comment: false
2

3
coverage:
4
  status:
5
    project:
6
      default:
7
        target: auto
8
        threshold: 1%
9
    patch:
10
      default:
11
        target: auto
12
        threshold: 1%
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading