Trial Innovation Network Series
2019-11-04
RShiny
plotly
Packagejavascript D3
graphics model plotly
ggplotly
function: pass any ggplot2
graphics object through it to get interactivityplotly
Graphics Functions in Hmisc
and rms
Packagespbc
DatasetHmisc::describe
: Tabular Outputdescribe
: Categorical Variablesp <- plot(d); p$Categorical
p$Continuous
Hmisc::summaryM
to Stratify by drug
s <- summaryM(bili + albumin + stage + protime + sex + age + spiders + alk.phos + sgot + chol ~ drug, data=pbc, overall=FALSE, test=TRUE)
plot(s, which='categorical')
plot(s, which='continuous', vars=1 : 4)
Hmisc::histboxp
on support2
DatasetgetHdata(support2) with(support2, { units(meanbp) <- 'mmHg' histboxp(x=meanbp, group=dzgroup, sd=TRUE, bins=200) } )
rms::survplotp
require(rms)
f <- npsurv(Surv(fu.yrs, status) ~ spiders, data=pbc) survplotp(f, time.inc=1, times=c(5, 10), fun=function(y) 1 - y)
htmlTable
and Hmisc
Packageshtml(s, caption='Baseline characteristics by randomized treatment', exclude1=TRUE, npct='both', digits=3, prmsd=TRUE, brmsd=TRUE, msdsize=mu$smaller2)
greport
and hreport
greport
Packageknitr
+ LaTeX
+ pdflatex
+ Acrobat Readerjavascript
show detailjavascript
in pdf
files, for pop-ups etc.LaTeX
is hardpdf
into Word
doesn’t work wellhreport
Packagejavascript
htmlTable
package and Hmisc
summaryM
LaTeX
Hmisc
package markupSpecs
list
: large number of translations and helper functionsLaTeX/HTML
translation tables for functionshreport
hreport
Example html Reportsbiostat.mc.vanderbilt.edu/RCTGraphics
github.com/harrelfe
safetyGraphics