Skip to content

Commit

Permalink
Updating paper title. Dropping CI calibration from sensitivity analysis.
Browse files Browse the repository at this point in the history
  • Loading branch information
schuemie committed Apr 9, 2018
1 parent d131a32 commit 42a8bd6
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 16 deletions.
6 changes: 5 additions & 1 deletion SystematicEvidence/plots.R
Original file line number Diff line number Diff line change
Expand Up @@ -80,19 +80,23 @@ plotPs <- function(ps, target, comparator) {
return(plot)
}

plotForest <- function(estimate) {
plotForest <- function(estimate, showCalibrated = TRUE) {
d1 <- data.frame(logRr = estimate$logRr,
logLb95Rr = log(estimate$ci95lb),
logUb95Rr = log(estimate$ci95ub),
database = estimate$db,
type = "Uncalibrated")
if (showCalibrated) {
d2 <- data.frame(logRr = estimate$calLogRr,
logLb95Rr = log(estimate$calCi95lb),
logUb95Rr = log(estimate$calCi95ub),
database = estimate$db,
type = "Calibrated")

d <- rbind(d1, d2)
} else {
d <- d1
}
d$significant <- d$logLb95Rr > 0 | d$logUb95Rr < 0

breaks <- c(0.25, 0.5, 1, 2, 4, 6, 8, 10)
Expand Down
20 changes: 10 additions & 10 deletions SystematicEvidence/server.R
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ shinyServer(function(input, output) {
output$sensitivityAnalysisPlot <- renderPlot({
sensitivityAnalysis <- sensitivityAnalysis()
if (is.null(sensitivityAnalysis)) return(NULL)
plotForest(sensitivityAnalysis)
plotForest(sensitivityAnalysis, showCalibrated = FALSE)
})

output$sensitivityAnalysisTable <- renderTable({
Expand All @@ -267,18 +267,18 @@ shinyServer(function(input, output) {
", p = ",
formatC(estimate$p, digits = 2, format = "f"),
")")
calHr <- paste0(formatC(estimate$calRr, digits = 2, format = "f"),
" (95% CI: ",
formatC(estimate$calCi95lb, digits = 2, format = "f"),
"-",
formatC(estimate$calCi95ub, digits = 2, format = "f"),
", p = ",
formatC(estimate$calP, digits = 2, format = "f"),
")")
# calHr <- paste0(formatC(estimate$calRr, digits = 2, format = "f"),
# " (95% CI: ",
# formatC(estimate$calCi95lb, digits = 2, format = "f"),
# "-",
# formatC(estimate$calCi95ub, digits = 2, format = "f"),
# ", p = ",
# formatC(estimate$calP, digits = 2, format = "f"),
# ")")
p(HTML(paste0("Using an intent-to-treat instead of a per-protocol analysis, when comparing the risk of ", point$outcomeName, " between new users of ", point$targetName,
" and ", point$comparatorName, " in the ", point$db,
" database, the estimated <b>uncalibrated hazard ratio</b> was <b>",hr,
"</b>, the estimated <b>calibrated hazard ratio</b> was <b>", calHr, "</b>.")))
"</b>.")))
})

# Literature --------------------------------------------------------------
Expand Down
9 changes: 4 additions & 5 deletions SystematicEvidence/ui.R
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
library(shiny)

shinyUI(fluidPage(style = 'width:1000px;',
titlePanel("Supplementary data for 'Improving reproducibility using high-throughput observational studies with empirical calibration: comparing all depression treatments'"),
titlePanel("Supplementary data for 'Improving reproducibility using high-throughput observational studies with empirical calibration'"),
tabsetPanel(
tabPanel("Systematically generated evidence",
fluidRow(
Expand Down Expand Up @@ -70,8 +70,7 @@ shinyUI(fluidPage(style = 'width:1000px;',
div(strong("Table S1.2."),"Counts of subjects, person-days and outcomes in the target and comparator population.")),
column(4,
plotOutput("sensitivityAnalysisPlot", height = "200px"),
div(strong("Figure S1.6."),"Hazard ratios and confidence intervals (CI) across the databases, both
calibrated (top) and uncalibrated (bottom). Blue indicates the CI includes one, orange indicates
div(strong("Figure S1.6."),"Hazard ratios and confidence intervals (CI) across the databases. Blue indicates the CI includes one, orange indicates
the CI does not include one."))
)
)
Expand Down Expand Up @@ -104,8 +103,8 @@ shinyUI(fluidPage(style = 'width:1000px;',
br(),
p("Supplementary data for:"),
p("Schuemie MJ, Ryan PB, Hripcsak G, Madigan D, Suchard MA,",
em("A systematic approach to improving the reliability and scale of evidence from health care data."),
", ...")
em("Improving reproducibility using high-throughput observational studies with empirical calibration."),
", Phil. Trans. R. Soc. A, 2018")
)
)
)
Expand Down

0 comments on commit 42a8bd6

Please sign in to comment.