Return to Statistical Graphics Home

Please rate the graphic:

%VOTE{id="Evalgraph" stars1="Graph Rating" global="off" open="off" secret="off" format="| $key | $small
Score: $score, My vote: $mylast, Total votes: $sum |" }%

Please add comments and then click on the "Add comment" button.

%COMMENT%

OriginalStatGraphicsForm edit

Image %LIGHTBOX{ image="VSsbp.png" thumbnail="tn_VSsbp.jpg" caption="SBP by Visit" }% Click on image to enlarge.
Title Systolic Blood Pressure (Main Profiles)
Graph_Subgroup General Principles
Code Added Yes
Description For each treatment group, a 95% confidence of the mean systolic blood pressure is calculated for each visit. The number of subjects with measurements at each visit is included in the lower portion of the graph.
Contributor/Email Mat Soukup (email: Mat.Soukup@fda.hhs.gov)
Background This is an example to show that blood pressure increases up through visit 5 and then returns towards baseline for the active.
Special Considerations
Date Original
Original Date 2007
Modified Date
Use/Suitability Presentation
Software Program R
Software
R-Code - Attachment R-script: Systolic Blood Pressure (Mean Profiles} - Attached
R-Code library(lattice)
library(Hmisc)

set.seed(46)
sbpc <- round(c(rnorm(10, 118, 5)), 1)<br /> sbpc[c(1,9,10)] <- c(119.1,118.6,117.7)<br />sbpa <- c(118.1, 122.7, 125.6, 133.1, 136.7, 134.2, 131.0, 126.2, 124.3, 125.1)<br />sda <- round(rnorm(10, 1.2, .1),1)<br />sdc <- round(rnorm(10, 1.2, .1),1)<br />na <- c(112, 112, 111, 110, 110, 108, 106, 105, 104, 102)<br />nc <- c(113, 112, 110, 108, 108, 108, 104, 103, 100, 100)<br />lcla <- sbpa-round(1.96*sda/sqrt(sda),1)<br />ucla <- sbpa+round(1.96*sda/sqrt(sda),1)<br />lclc <- sbpc-round(1.96*sdc/sqrt(sdc),1)<br />uclc <- sbpc+round(1.96*sdc/sqrt(sdc),1)<br /># Write out table to be used in slides
dat <- data.frame(na,sbpa,sda,lcla,ucla,nc,sbpc,sdc,lclc,uclc)<br />


plotdat <- data.frame(Mean=c(sbpa,sbpc),<br /> UCL=c(ucla,uclc),
LCL=c(lcla,lclc),
xx=c(1:10-.1,1:10+.1),
TRT=as.factor(rep(c('Active','Control'), each=10)))

#### Create the vital signs graph
#png('C:/Research/Graphics/Graphs4Display/webpages/classes/pages/images/VSsbp.png',
# width=500, height=500)

new.back <- trellis.par.get("background")<br />new.back$col <- "white"<br />newcol <- trellis.par.get("superpose.symbol")<br />newcol$col <- c('blue','black')<br />newcol$pch <- c(16,17,4,8)<br />new.line <- trellis.par.get("superpose.line")<br />new.line$col <- c('blue','black')<br />new.line$lty <- c(1,1,1,1)<br />new.pan <- trellis.par.get("strip.background")<br />new.pan$col <- c('gray90','white')<br />trellis.par.set("background", new.back)
trellis.par.set("superpose.symbol", newcol)
trellis.par.set("superpose.line", new.line)
trellis.par.set("strip.background",new.pan)

xYplot(Cbind(Mean,LCL,UCL)~xx, groups=TRT, data=plotdat,
type='b',
ylim=c(min(c(lcla,lclc))-3.5, max(c(ucla,uclc))+1), ph=1.5, lwd=2,
xlab='Vist Number',
ylab='Systolic Blood Pressure',
pch=trellis.par.get('superpose.symbol')$pch[1:2],
label.curves=FALSE,
cex=1.25,
scales=list(y=list(at=c(111,110,115,120,125,130,135),
labels=c(expression(N[C]),expression(N[A]),'115','120','125','130','135')),
x=list(at=1:10, labels=1:10)),
key=list(
lines=list(type='o',
col=trellis.par.get("superpose.symbol")$col[1:2],
lty=trellis.par.get('superpose.line')$lty[1:2],
pch=trellis.par.get('superpose.symbol')$pch[1:2],
size=3),
text=list(
lab=c('Active','Control'),
col=trellis.par.get('superpose.line')$col[1:2]),
columns=2, title='Treatment'))
trellis.focus('panel',1,1, highlight=FALSE)
ltext(1:10, rep(111,10), labels=nc, col='black')
ltext(1:10, rep(110,10), labels=na, col='blue')
trellis.unfocus()
#dev.off()
SAS-Code - Attachment
SAS-Code
Stata-Code - Attachment
Stata-Code
Other Code - Attachment
Other Code
Keywords safety analysis, treatment group, confidence interval
OPTIONAL FIELDS
References
Datasets
Data
Attached Data
CATEGORIZATIONS
Classification-Evaluation Safety
Classification-Graph Type
Graph_Type Line Plot
Variable Relationship Continuous versus Categorical
Data Types Categorical and Continuous
Special Cases
Disclaimer The views expressed within CTSpedia are those of the author and must not be taken to represent policy or guidance on the behalf of any organization or institution with which the author is affiliated.
Permission Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF ERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT OLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Reference Image VSsbp_Reference_200.png
This topic: CTSpedia > WebHome > StatGraphHome > ContributeGraphics > StatGraphTopic016
Topic revision: 18 Jun 2012, MaryBanach
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback