tableplot | R Documentation |
Function constructs a plot for two categorical variables based on table function
tableplot(x, y = NULL, labels = TRUE, legend = FALSE, points = TRUE,
...)
x |
First categorical variable. Can be either vector, factor, matrix or a data
frame. If |
y |
Second categorical variable. If not provided, then only |
labels |
Whether to print table labels inside the plot or not. |
legend |
If |
points |
Whether to plot points in the areas. They help in understanding how many values lie in specific categories. |
... |
Other parameters passed to the plot function. |
The function produces the plot of the table()
function with colour densities
corresponding to the respective frequencies of appearance. If the value appears more
often than the other (e.g. 0.5 vs 0.15), then it will be darker. The frequency of 0
corresponds to the white colour, the frequency of 1 corresponds to the black.
See details in the vignette "Marketing analytics with greybox":
vignette("maUsingGreybox","greybox")
Function does not return anything. It just plots things.
Ivan Svetunkov, ivan@svetunkov.ru
plot, table, spread
tableplot(mtcars$am, mtcars$gear)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.