View source: R/segmentcomparisontable.R
SegmentComparisonTable | R Documentation |
SegmentComparisonTable
Creates a html table allowing comparison between segments using variables or variable sets
SegmentComparisonTable(
x,
group,
weights = NULL,
subset = TRUE,
row.names.to.remove = "",
format.numeric.decimals = 1,
format.percentage.decimals = 0,
format.conditional.fill = NULL,
format.numeric.fill.colors = "#E99598, #E5C8C4, #A9C0DA, #82A5CB",
format.percentage.fill.colors = "#E99598, #E5C8C4, #A9C0DA, #82A5CB",
cond.shade = c("None", "Cell colors", "Font colors", "Boxes", "Arrows",
"Fonts and arrows")[2],
cond.box.radius = 0,
cond.box.width = 2,
cond.bar.radius = 13,
cond.shade.colors = c("#E99598", "#E5C8C4", "#A9C0DA", "#82A5CB"),
cond.shade.cutoffs = c(-0.2, -0.1, 0.1, 0.2),
cond.shade.sig.only = FALSE,
show.index.values = FALSE,
cell.fill = "#FFFFFF",
font.color = "#2C2C2C",
font.size = 10,
font.unit = "px",
row.height = paste0(font.size + 5, font.unit),
font.color.set.if.nonsignificant = TRUE,
font.color.nonsignificant = "#999999",
font.color.confidence = 0.95,
font.color.FDRcorrection = FALSE,
font.color.nonparametric = FALSE,
show.question.name = TRUE,
col.header.labels = NULL,
col.widths = "100px, 100px",
row.header.font.weight = "normal",
row.span.font.weight = "normal",
col.header.font.weight = "normal",
row.header.pad = 5,
row.span.pad = row.header.pad,
row.header.fill = "#F1F3F4",
row.span.fill = row.header.fill,
col.header.fill = "#AEB7BA",
corner.fill = col.header.fill,
summary.header.fill = col.header.fill,
summary.cell.fill = "#D1D7D9",
...
)
x |
A list of variables or variable sets. These can be numeric or categorical (PickOne or PickAny). It is expected that the attributes for "question", "label" and "questiontype" is defined. |
group |
The segmentation variable. Should be a factor. |
weights |
Numeric; An optional vector of sampling weights.
Should be the same length as |
subset |
An optional vector specifying a subset of observations to be used. |
row.names.to.remove |
Character vector or delimited string of row labels specifying rows to remove from the returned table. |
format.numeric.decimals |
The number of decimals shown in the output table for numeric values. |
format.percentage.decimals |
The number of decimals shown in the output table for percentage values. |
format.conditional.fill |
Deprecated. Whether the fill color of the cells should reflect the value in the cells. |
format.numeric.fill.colors |
Deprecated. |
format.percentage.fill.colors |
Deprecated |
cond.shade |
What should be shaded to reflect the magnitude of the value in each cell. One of "None", "Cell colors", "Font colors", "Boxes", "Arrows", Fonts and arrows". |
cond.box.radius |
Numeric; roundness of box corner when
|
cond.box.width |
Numeric; line width of box when
|
cond.bar.radius |
Numeric; roundness of bar corner when
|
cond.shade.colors |
A vector of 4 colors (in order) which will be used when values are 1) very small, 2)small, 3) large, 4) very large. |
cond.shade.cutoffs |
A vector of cutoffs used to evaluate whether values are very small/small/large/very large. Categorical variables are standardized by dividing by the same statistic computed over the whole populatoon. Numeric variables are standardized by dividing twice the standard deviation http://www.stat.columbia.edu/~gelman/research/published/standardizing7.pdf |
cond.shade.sig.only |
Logical; whether conditional shading should only be applied to cells with significant values. |
show.index.values |
Values are shown as a ratio to the total computed on the whole population (i.e. unsegmented). |
cell.fill |
The default background color of the cells in the table. |
font.color |
Default font color of the cells in the table. |
font.size |
Default font size. |
font.unit |
One of "px" or "pt". |
row.height |
Height of one row in the table (includes units). |
font.color.set.if.nonsignificant |
Logical; whether p-values should be computed to test the significance of the value in the table. |
font.color.nonsignificant |
Font color used to show insignificant values if
|
font.color.confidence |
The confidence level below which insignificant values
should be shown in |
font.color.FDRcorrection |
Logical; whether an FDR correction is applied to deal with multiple testing. |
font.color.nonparametric |
Logical; whether a non-parametric i test should be used. |
show.question.name |
Whether the question name should be shown in the output table. |
col.header.labels |
A vector or comma-separated labels to override the column name |
col.widths |
Vector or comma-separated list to control column widths. |
row.header.font.weight |
One of "bold" or "normal". |
row.span.font.weight |
One of "bold" or "normal". |
col.header.font.weight |
One of "bold" or "normal". |
row.header.pad |
Numeric; Space between border and text in pixels. |
row.span.pad |
Numeric; Space between border and text in pixels. |
row.header.fill |
Background color of row header cells. |
row.span.fill |
Background color of row span cells. |
col.header.fill |
Background color of column header cells. |
corner.fill |
Background color of corner cells. |
summary.header.fill |
The background color of the row headers in the first two rows in the table which given a summary of the segmentation variable. |
summary.cell.fill |
The background color of the first two rows in the table which gives a summary of the segmentation variable. |
... |
Other parameters passed to CreateCustomTable. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.