expand_statdoc: Expand staticdocs index.html File

Description Usage Arguments Examples

View source: R/expand_statdoc.R

Description

staticdocs writes multiple files contained in an .Rd file to one icon followed by a parenthesis with the other functions. This function exapands the parenthesis to be separate icons of their own.

Usage

1
2
expand_statdoc(path, file = NULL, to.icon = NULL, readme = NULL,
  combine = NULL, drop = NULL, rm.other = TRUE)

Arguments

path

Path to the index.html file.

file

The path/file name to output. If NULL the original index is overwritten.

to.icon

The extra functions found in the parenthesis for who new icons should be added.

readme

Path to the readme file.

combine

A list of vectors to combine together. The functions will be combined int he order of each vector.

drop

A character vector of functions in the parenthesis that should be excluded from the index file.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
## Not run: 
(examp <- system.file("extdata/qdap", package = "acc.roxygen2"))
file.copy(examp, to=getwd(), recursive = TRUE)
path <- paste0(getwd(), "/qdap/index.html")
file <- paste0(getwd(), "/qdap/index2.html")

library(qdap)
expand_statdoc(path, file, drop = qcv(syn, mgsub, adjmat, wc))

file2 <- paste0(getwd(), "/qdap/index3.html")
extras <- qcv(right.just, coleman_liau, flesch_kincaid, fry, linsear_write, SMOG)
expand_statdoc(path, file2, to.icon = extras, drop = qcv(syn, mgsub, adjmat, wc))

file3 <- paste0(getwd(), "/qdap/index4.html")
rdme <- system.file("extdata/readme.R", package = "acc.roxygen2")
expand_statdoc(path, file3, to.icon = extras,
    readme = rdme, combine = qcv(character.table, char.table),
    drop = qcv(syn, mgsub, adjmat, wc))

## End(Not run)

trinker/acc.roxygen2 documentation built on May 27, 2017, 1:45 p.m.