View source: R/plotTable1Mat.R
plotTable1Heatmap | R Documentation |
Plot a heatmap of table 1, either by plotting p values, n of patients colored by p-values or n of patients colored by percentage of total patients
plotTable1Heatmap(factorList, method = c("AssociationByP", "CrosstableByP", "CrosstableByN")[1], drawRaster = NULL, ...)
factorList |
named list with clinical variables coded as factors |
method |
'AssociationByP' : draw a heatmap with p-values of the association between parameters and a direction of effect if a Fisher Exact test was performed. 'CrosstableByP' : draw a heatmap with p-values of the association between parameters and show the crosstables 'CrosstableByN' : draw a heatmap with percentage of patients in the cell of a crosstable and show the crosstables |
drawRaster |
draw horizontal and vertical lines marking characteristics |
... |
plotting parameters for image |
lst <- list(a=sample(c(TRUE,FALSE), 10, replace=TRUE), b=sample(c(TRUE,FALSE), 10, replace=TRUE), c=sample(c(TRUE,FALSE), 10, replace=TRUE)) lst <- lapply(lst, as.factor) dev.new(height=10, width=10) plotTable1Heatmap(factorList=lst, method='AssociationByP', drawRaster=TRUE) plotTable1Heatmap(factorList=lst, method='CrosstableByP', drawRaster=TRUE) plotTable1Heatmap(factorList=lst, method='CrosstableByN', drawRaster=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.