[Diagnosismed-commits] r6 - in pkg/DiagnosisMed: . R chm man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Mon Mar 2 13:00:59 CET 2009
Author: pedrobrasil
Date: 2009-03-02 13:00:59 +0100 (Mon, 02 Mar 2009)
New Revision: 6
Modified:
pkg/DiagnosisMed/DESCRIPTION
pkg/DiagnosisMed/R/ROC.r
pkg/DiagnosisMed/chm/00Index.html
pkg/DiagnosisMed/chm/ROC.html
pkg/DiagnosisMed/chm/diagnosis.html
pkg/DiagnosisMed/chm/interact.ROC.html
pkg/DiagnosisMed/chm/plot.diag.html
pkg/DiagnosisMed/man/ROC.Rd
pkg/DiagnosisMed/man/diagnosis.Rd
pkg/DiagnosisMed/man/interact.ROC.Rd
pkg/DiagnosisMed/man/plot.diag.Rd
Log:
Modified: pkg/DiagnosisMed/DESCRIPTION
===================================================================
--- pkg/DiagnosisMed/DESCRIPTION 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/DESCRIPTION 2009-03-02 12:00:59 UTC (rev 6)
@@ -1,6 +1,6 @@
Package: DiagnosisMed
-Version: 0.1.2
-Date: 2008-09-28
+Version: 0.1.2.1
+Date: 2009-02-27
Author: Pedro Brasil <pedro.brasil at ipec.fiocruz.br>
Maintainer: Pedro Brasil <pedro.brasil at ipec.fiocruz.br>
Depends: R (>= 2.7.2),epitools,epicalc, TeachingDemos, tcltk
Modified: pkg/DiagnosisMed/R/ROC.r
===================================================================
--- pkg/DiagnosisMed/R/ROC.r 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/R/ROC.r 2009-03-02 12:00:59 UTC (rev 6)
@@ -31,19 +31,12 @@
colnames(test.summary)<-c("Min.","1st Qu.","Median","Mean","3rd Qu.","Max.","SD")
rownames(test.summary)<-c("Overall summary","Without disease", "With disease")
# Estimating the AUC and confidence limits, inspired in auc{PresenceAbsence}
- AUC <- ((as.double(length(test[gold == 0]))) * (as.double(length(test[gold ==
- 1]))) + ((as.double(length(test[gold == 0]))) * ((as.double(length(
- test[gold == 0]))) + 1))/2 - sum(rank(test,ties.method = "average")[
- gold == 0]))/((as.double(length(test[gold == 0]))) * (as.double(
- length(test[gold == 1]))))
+ # m length(test[gold == 0])
+ # n length(test[gold == 1])
+ AUC <- ((as.double(length(test[gold == 0]))) * (as.double(length(test[gold ==1]))) + ((as.double(length(test[gold == 0]))) * ((as.double(length(test[gold == 0]))) + 1))/2 - sum(rank(test,ties.method = "average")[gold == 0]))/((as.double(length(test[gold == 0]))) * (as.double(length(test[gold == 1]))))
AUC[AUC < 0.5] <- 1 - AUC
- SD.AUC <- (((var(((rank(test, ties.method = "average")[gold == 0]) -
- rank(test[gold == 0], ties.method = "average"))/
- (as.double(length(test[gold == 1])))))/(as.double(length(test[gold == 0]))))
- + ((var(((rank(test, ties.method = "average")[gold == 1]) -
- rank(test[gold == 1], ties.method = "average"))/
- (as.double(length(test[gold == 0])))))/
- (as.double(length(test[gold == 1])))))^0.5
+ X<-test[gold==0] # pag 209
+ Y<-test[gold==1] # pag 209
}
if (is.factor(gold)==TRUE){
# The same tests summary but with different reference standard codes
@@ -52,23 +45,23 @@
test.summary<-rbind(test.summary,round(c(summary(test[gold=="positive"]),sd(test[gold=="positive"])),digits=5))
colnames(test.summary)<-c("Min.","1st Qu.","Median","Mean","3rd Qu.","Max.","SD")
rownames(test.summary)<-c("Overall summary","Without disease", "With disease")
- AUC <- ((as.double(length(test[gold =="negative"]))) * (as.double(length(test[gold ==
- "positive"]))) + ((as.double(length(test[gold =="negative"]))) * ((as.double(length(
- test[gold =="negative"]))) + 1))/2 - sum(rank(test,ties.method = "average")[
- gold =="negative"]))/((as.double(length(test[gold =="negative"]))) * (as.double(
- length(test[gold == "positive"]))))
+ AUC <- ((as.double(length(test[gold =="negative"]))) * (as.double(length(test[gold =="positive"]))) + ((as.double(length(test[gold =="negative"]))) * ((as.double(length(test[gold =="negative"]))) + 1))/2 - sum(rank(test,ties.method = "average")[gold =="negative"]))/((as.double(length(test[gold =="negative"]))) * (as.double(length(test[gold == "positive"]))))
AUC[AUC < 0.5] <- 1 - AUC
- SD.AUC <- (((var(((rank(test, ties.method = "average")[gold == "negative"]) -
- rank(test[gold == "negative"], ties.method = "average"))/
- (as.double(length(test[gold =="positive"])))))/(as.double(length(test[gold =="negative"]))))
- + ((var(((rank(test, ties.method = "average")[gold =="positive"]) -
- rank(test[gold =="positive"], ties.method = "average"))/
- (as.double(length(test[gold =="negative"])))))/
- (as.double(length(test[gold =="positive"])))))^0.5
+ X<-test[gold=="negative"] # pag 209
+ Y<-test[gold=="positive"] # pag 209
}
- AUC.summary<-c(AUC-SD.AUC,AUC,AUC+SD.AUC)
+ m<-length(X) # pag 209
+ n<-length(Y) # pag 209
+ D10X<-function(Xi){(1/n)*sum(Y>=Xi)} # pag 211
+ D01Y<-function(Yi){(1/m)*sum(Yi>=X)} # pag 211
+ VAR.AUC<-sum((tapply(X,X,"D10X")-AUC)^2)/(m*(m-1))+sum((tapply(Y,Y,"D01Y")-AUC)^2)/(m*(m-1))
+ VAR.AUC<-(1/(m*(m-1)))*(sum((tapply(X,X,"D10X")-AUC)^2)+(1/(n*(n-1)))*sum((tapply(Y,Y,"D01Y")-AUC)^2)) # pag 211
+ SD.AUC<-sqrt(VAR.AUC)
+ alpha<-1-CL
+ AUC.summary<-c(AUC- qnorm(1-alpha/2)*SD.AUC,AUC,AUC+ qnorm(1-alpha/2)*SD.AUC)
names(AUC.summary)<-c("AUC inf conf limit", "AUC","AUC sup conf limit")
+
#TP sum(test.table[i:nrow(test.table),2])
#FP sum(test.table[i:nrow(test.table),1])
#TN sum(test.table[1:i-1,1])
@@ -212,8 +205,8 @@
if(Plot.point=="Max.Accuracy")
{points(1-test.diag.table$Specificity[which.max(test.cutoff.table$Accuracy)],
test.diag.table$Sensitivity[which.max(test.cutoff.table$Accuracy)],
- col=1,pch=19)
- title(sub="Cut-off estimated by maximazing accuracy")
+ col=1,pch=19)
+ title(sub="Cut-off estimated by maximazing accuracy",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.max
(test.cutoff.table$Accuracy)],digits=4)),
@@ -222,12 +215,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.max
(test.cutoff.table$Accuracy)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Max.DOR")
{points(1-test.diag.table$Specificity[which.max(test.cutoff.table$DOR)],
test.diag.table$Sensitivity[which.max(test.cutoff.table$DOR)],
- col=1,pch=19)
- title(sub="Cut-off estimated by maximazing diagnostic odds ratio")
+ col=1,pch=19)
+ title(sub="Cut-off estimated by maximazing diagnostic odds ratio",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.max
(test.cutoff.table$DOR)],digits=4)),
@@ -236,12 +229,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.max
(test.cutoff.table$DOR)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Error.rate")
{points(1-test.diag.table$Specificity[which.min(test.cutoff.table$Error.rate)],
test.diag.table$Sensitivity[which.min(test.cutoff.table$Error.rate)],
- col=1,pch=19)
- title(sub="Cut-off estimated by minimizing error rate")
+ col=1,pch=19)
+ title(sub="Cut-off estimated by minimizing error rate",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.min
(test.cutoff.table$Error.rate)],digits=4)),
@@ -250,12 +243,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.min
(test.cutoff.table$Error.rate)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Max.Accuracy.area")
{points(1-test.diag.table$Specificity[which.max(test.cutoff.table$Accuracy.area)],
test.diag.table$Sensitivity[which.max(test.cutoff.table$Accuracy.area)],
- col=1,pch=19)
- title(sub="Cut-off estimated by maximazing the area related to accuracy")
+ col=1,pch=19)
+ title(sub="Cut-off estimated by maximazing the area related to accuracy",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.max
(test.cutoff.table$Accuracy.area)],digits=4)),
@@ -264,12 +257,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.max
(test.cutoff.table$Accuracy.area)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Max.Sens+Spec")
{points(1-test.diag.table$Specificity[which.max(test.cutoff.table$Max.Se.Sp)],
test.diag.table$Sensitivity[which.max(test.cutoff.table$Max.Se.Sp)],
- col=1,pch=19)
- title(sub="Cut-off value where the sum Se + Sp is maximized")
+ col=1,pch=19)
+ title(sub="Cut-off value where the sum Se + Sp is maximized",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.max
(test.cutoff.table$Max.Se.Sp)],digits=4)),
@@ -278,12 +271,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.max
(test.cutoff.table$Max.Se.Sp)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Max.Youden")
{points(1-test.diag.table$Specificity[which.max(test.cutoff.table$Youden)],
test.diag.table$Sensitivity[which.max(test.cutoff.table$Youden)],
- col=1,pch=19)
- title(sub="Cut-off estimated by maximazing Youden Index")
+ col=1,pch=19)
+ title(sub="Cut-off estimated by maximazing Youden Index",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.max
(test.cutoff.table$Youden)],digits=4)),
@@ -292,12 +285,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.max
(test.cutoff.table$Youden)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Se=Sp")
{points(1-test.diag.table$Specificity[which.min(test.cutoff.table$Se.equals.Sp)],
test.diag.table$Sensitivity[which.min(test.cutoff.table$Se.equals.Sp)],
col=1,pch=19)
- title(sub="Cut-off value where Se is the closest to Sp")
+ title(sub="Cut-off value where Se is the closest to Sp",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.min
(test.cutoff.table$Se.equals.SP)],digits=4)),
@@ -306,12 +299,12 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.min
(test.cutoff.table$Se.equals.SP)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Min.ROC.Dist")
{points(1-test.diag.table$Specificity[which.min(test.cutoff.table$MinRocDist)],
test.diag.table$Sensitivity[which.min(test.cutoff.table$MinRocDist)],
- col=1,pch=19)
- title(sub="Cut-off that minimizes the distance between the curve and upper left corner")
+ col=1,pch=19)
+ title(sub="Cut-off that minimizes the distance between the curve and upper left corner",cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.min
(test.cutoff.table$MinRocDist)],digits=4)),
@@ -320,13 +313,13 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.min
(test.cutoff.table$MinRocDist)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Max.Efficiency")
{points(1-test.diag.table$Specificity[which.max(test.cutoff.table$Efficiency)],
test.diag.table$Sensitivity[which.max(test.cutoff.table$Efficiency)],
- col=1,pch=19)
- title(sub=paste("Cut-off maximizing efficiency: population prevalence =",
- formatC(pop.prevalence,digits=2)))
+ col=1,pch=19)
+ title(sub=paste("Cut-off maximizing efficiency: population prevalence =",
+ formatC(pop.prevalence,digits=2)),cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.max
(test.cutoff.table$Efficiency)],digits=4)),
@@ -335,14 +328,14 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.max
(test.cutoff.table$Efficiency)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
if(Plot.point=="Min.MCT")
{points(1-test.diag.table$Specificity[which.min(test.cutoff.table$MCT)],
test.diag.table$Sensitivity[which.min(test.cutoff.table$MCT)],
- col=1,pch=19)
- title(sub=paste("Cut-off minimazing MCT: population prevalence =",
- formatC(pop.prevalence,digits=2),"; cost(FN)/cost(FP)=",
- formatC(Cost,digits=2)))
+ col=1,pch=19)
+ title(sub=paste("Cut-off minimazing MCT: population prevalence =",
+ formatC(pop.prevalence,digits=2),"; cost(FN)/cost(FP)=",
+ formatC(Cost,digits=2)),cex.sub=0.85)
legend("bottomright",legend=(c(
paste("cut off:",formatC(test.cutoff.table$test.values[which.min
(test.cutoff.table$MCT)],digits=4)),
@@ -351,7 +344,7 @@
paste("Specificity:",formatC(test.diag.table$Specificity[which.min
(test.cutoff.table$MCT)],digits=4)),
paste("AUC:",formatC(AUC,digits=4))
- )))}
+ )),bty="n")}
}
names(pop.prevalence)<-c("Informed disease prevalence - same as sample prevalence if not informed")
names(sample.prevalence)<-c("Observed prevalence by gold standard")
Modified: pkg/DiagnosisMed/chm/00Index.html
===================================================================
--- pkg/DiagnosisMed/chm/00Index.html 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/chm/00Index.html 2009-03-02 12:00:59 UTC (rev 6)
@@ -10,7 +10,7 @@
<param name="keyword" value=".. contents">
</object>
-<h2>Help pages for package ‘DiagnosisMed’ version 0.1.2</h2>
+<h2>Help pages for package ‘DiagnosisMed’ version 0.1.2.1</h2>
<table width="100%">
Modified: pkg/DiagnosisMed/chm/ROC.html
===================================================================
--- pkg/DiagnosisMed/chm/ROC.html 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/chm/ROC.html 2009-03-02 12:00:59 UTC (rev 6)
@@ -53,7 +53,7 @@
"positive" - with the target disease.</td></tr>
<tr valign="top"><td><code>test</code></td>
<td>
-The index test or test under evaluation. A column in a dataframe or
+The index test or test under evaluation. A column in a dataframe or vector
indicating the test results in a continuous scale. May also work with discrete
ordinal scale.</td></tr>
<tr valign="top"><td><code>CL</code></td>
@@ -127,11 +127,15 @@
that behave like glucose (middle values are supposed to be normal and
extreme values are supposed to be abnormal) and immunefluorescence (lower
values - higher dilutions - are suppose to be abnormal) will not be correctly
-analyzed. In the latter example, multiplying the test results by -1 or other
+analyzed. In the latter, multiplying the test results by -1 or other
transformation before analysis could make it work. The result table with the
-Print.full option, has more columns than can be shown in the screen. R
+Print.full option, may have more columns than can be shown in the screen. R
automatically shows these columns below, therefore one has to be careful when
-relating the corresponding lines.
+relating the corresponding lines. The AUC (area under the ROC curve) is estimated
+by the trapezoidal method (also known as Mann-Whitney statistic), its confidence
+interval is estimated by DeLong method. The validity measures such as
+Sensitivity, Specificity and Likelihood ratios are estimated as
+in <code><a href="diagnosis.html">diagnosis</a></code> function.
</p>
<p>
Diagnostic odds ratio: <i>DOR = (TP*TN)/(FN*FP); the same as: DOR = PLR/NLR</i>
@@ -185,14 +189,14 @@
<h3>Note</h3>
<p>
-Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
+Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed email list, or R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
</p>
<h3>Author(s)</h3>
<p>
-Pedro Brasil - <a href="mailto:pedro.brasil at ipec.fiocruz.br">pedro.brasil at ipec.fiocruz.br</a>
+Pedro Brasil - <a href="mailto:diagnosismed-list at lists.r-forge.r-project.org">diagnosismed-list at lists.r-forge.r-project.org</a>
</p>
@@ -213,13 +217,15 @@
<p>
Greiner, M. (1996) Two-graph receiver operating characteristic (TG-ROC): update version supports optimisation of cut-off values that minimize overall misclassification costs. J.Immunol.Methods 191:93-94.
</p>
+<p>
+Gengsheng Qin, Lejla Hotilovac. Comparison of non-parametric confidence intervals for the area under the ROC curve of a continuous-scale disagnostic test. Statistical Methods in Medical Research 2008; 17:207-221.
+</p>
<h3>See Also</h3>
<p>
-<code><a href="diagnosis.html">diagnosis</a></code>,<code><a href="interact.ROC.html">interact.ROC</a></code>,<a onclick="findlink('PresenceAbsence', 'optimal.thresholds.html')" style="text-decoration: underline; color: blue; cursor: hand">optimal.thresholds</a>,
-<a onclick="findlink('epicalc', 'roc.from.table.html')" style="text-decoration: underline; color: blue; cursor: hand">roc.from.table</a>,<a onclick="findlink('ROCR', 'prediction.html')" style="text-decoration: underline; color: blue; cursor: hand">prediction</a>
+<a onclick="findlink('epitools', 'binom.conf.int.html')" style="text-decoration: underline; color: blue; cursor: hand">binom.conf.int</a>,<code><a href="diagnosis.html">diagnosis</a></code>,<code><a href="interact.ROC.html">interact.ROC</a></code>,<a onclick="findlink('ROCR', 'performance.html')" style="text-decoration: underline; color: blue; cursor: hand">performance</a>
</p>
@@ -228,17 +234,17 @@
<pre>
# loading a dataset
data(tutorial)
-# attaching a dataset
+# The reference standard is not in the correct format.
+# Recoding the reference standard to "positive" & "negative" in a new variable.
+tutorial$Gold2<-as.factor(ifelse(tutorial$Gold=="pos","positive","negative"))
+# Attaching the data set with the modifications.
attach(tutorial)
-# The reference standard is not in the correct format
-# Recoding the reference standard to "positive" & "negative"
-tutorial$Gold2<-as.factor(ifelse(Gold=="pos","positive","negative"))
-# attaching the data set with the modifications
-attach(tutorial)
# A little description of the data set to check if it is ok!
str(tutorial)
-# Running ROC analysis with the standard options
-ROC(Gold2,Test_B)
+# Running ROC analysis with the full table option.
+ROC(Gold2,Test_B,Print.full=TRUE)
+# Adding a title to the graph.
+title(main="ROC graph")
</pre>
<script Language="JScript">
@@ -252,6 +258,6 @@
</script>
-<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.0 <a href="00Index.html">Index]</a></div>
+<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.2.1 <a href="00Index.html">Index]</a></div>
</body></html>
Modified: pkg/DiagnosisMed/chm/diagnosis.html
===================================================================
--- pkg/DiagnosisMed/chm/diagnosis.html 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/chm/diagnosis.html 2009-03-02 12:00:59 UTC (rev 6)
@@ -148,14 +148,14 @@
<h3>Note</h3>
<p>
-Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
+Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed email list, or R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
</p>
<h3>Author(s)</h3>
<p>
-Pedro Brasil - <a href="mailto:pedro.brasil at ipec.fiocruz.br">pedro.brasil at ipec.fiocruz.br</a>
+Pedro Brasil - <a href="mailto:diagnosismed-list at lists.r-forge.r-project.org">diagnosismed-list at lists.r-forge.r-project.org</a>
</p>
@@ -175,7 +175,7 @@
<h3>See Also</h3>
<p>
-<code><a href="plot.diag.html">plot.diag</a></code>, <a onclick="findlink('epicalc', 'ROC.html')" style="text-decoration: underline; color: blue; cursor: hand">ROC</a>, <a onclick="findlink('epitools', 'binom.conf.int.html')" style="text-decoration: underline; color: blue; cursor: hand">binom.conf.int</a>,
+<code><a href="plot.diag.html">plot.diag</a></code>, <code><a href="ROC.html">ROC</a></code>, <a onclick="findlink('epitools', 'binom.conf.int.html')" style="text-decoration: underline; color: blue; cursor: hand">binom.conf.int</a>,
<a onclick="findlink('epibasix', 'sensSpec.html')" style="text-decoration: underline; color: blue; cursor: hand">sensSpec</a>,<a onclick="findlink('epiR', 'epi.tests.html')" style="text-decoration: underline; color: blue; cursor: hand">epi.tests</a>
</p>
@@ -225,6 +225,6 @@
</script>
-<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.0 <a href="00Index.html">Index]</a></div>
+<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.2.1 <a href="00Index.html">Index]</a></div>
</body></html>
Modified: pkg/DiagnosisMed/chm/interact.ROC.html
===================================================================
--- pkg/DiagnosisMed/chm/interact.ROC.html 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/chm/interact.ROC.html 2009-03-02 12:00:59 UTC (rev 6)
@@ -64,20 +64,31 @@
<h3>Value</h3>
<p>
-A ROC graph with a sliding button to interact and see the Sensitivity and
-Specificity changes while changing the cut-off.</p>
+interact.ROC generates two graphs in the same window: the upper graph is a ROC graph
+(Sensitivity on the vertical axis and 1-Specificity on the horizontal axis); the lower
+graph is a density plot (the density on the vertical axis and the test cut-off (or threshold)
+on the horizontal axis). With a sliding button is possible to interact and see how
+the Sensitivity and Specificity changes while changing the cut-off. In the upper graph
+the cut-off is represented by the different dots and the purple line represents the distance
+to the "optimal" threshold. At the lower graph, the red line and dashes represent the density
+and the test result from those without the target condition respectively. While the blue ones
+represent those with the target condition. If the dashes are at the bottom of the lower graph
+then they are classified as without the target condition, if at the top, with the target condition.
+The green vertical line represents the cut-off and changes with the sliding button. The
+cut-off itself can be seen right above the sliding button and the respective
+sensitivity and specificity at the bottom of the graph window.</p>
<h3>Note</h3>
<p>
-Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
+Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed email list, or R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
</p>
<h3>Author(s)</h3>
<p>
-Pedro Brasil - <a href="mailto:pedro.brasil at ipec.fiocruz.br">pedro.brasil at ipec.fiocruz.br</a>
+Pedro Brasil - <a href="mailto:diagnosismed-list at lists.r-forge.r-project.org">diagnosismed-list at lists.r-forge.r-project.org</a>
</p>
@@ -91,7 +102,7 @@
<h3>See Also</h3>
<p>
-<code><a href="diagnosis.html">diagnosis</a></code>,<code><a href="ROC.html">ROC</a></code>,<a onclick="findlink('epicalc', 'ROC.html')" style="text-decoration: underline; color: blue; cursor: hand">ROC</a>,<a onclick="findlink('TeachingDemos', 'roc.demo.html')" style="text-decoration: underline; color: blue; cursor: hand">roc.demo</a>
+<code><a href="diagnosis.html">diagnosis</a></code>,<code><a href="ROC.html">ROC</a></code>,<a onclick="findlink('ROCR', 'performance.html')" style="text-decoration: underline; color: blue; cursor: hand">performance</a>,<a onclick="findlink('TeachingDemos', 'roc.demo.html')" style="text-decoration: underline; color: blue; cursor: hand">roc.demo</a>
</p>
@@ -114,6 +125,6 @@
</script>
-<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.2 <a href="00Index.html">Index]</a></div>
+<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.2.1 <a href="00Index.html">Index]</a></div>
</body></html>
Modified: pkg/DiagnosisMed/chm/plot.diag.html
===================================================================
--- pkg/DiagnosisMed/chm/plot.diag.html 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/chm/plot.diag.html 2009-03-02 12:00:59 UTC (rev 6)
@@ -64,14 +64,14 @@
<h3>Note</h3>
<p>
-Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
+Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed email list, or R-Forge website <a href="https://r-forge.r-project.org/projects/diagnosismed/">https://r-forge.r-project.org/projects/diagnosismed/</a>.
</p>
<h3>Author(s)</h3>
<p>
-Pedro Brasil; <a href="mailto:pedro.brasil at ipec.fiocruz.br">pedro.brasil at ipec.fiocruz.br</a>
+Pedro Brasil - <a href="mailto:diagnosismed-list at lists.r-forge.r-project.org">diagnosismed-list at lists.r-forge.r-project.org</a>
</p>
@@ -85,7 +85,7 @@
<h3>See Also</h3>
<p>
-<code><a href="diagnosis.html">diagnosis</a></code>,<a onclick="findlink('Design', 'nomogram.html')" style="text-decoration: underline; color: blue; cursor: hand">nomogram</a>,<a onclick="findlink('epiR', 'epi.nomogram.html')" style="text-decoration: underline; color: blue; cursor: hand">epi.nomogram</a>
+<code><a href="diagnosis.html">diagnosis</a></code>,<a onclick="findlink('Design', 'nomogram.html')" style="text-decoration: underline; color: blue; cursor: hand">nomogram</a>,<a onclick="findlink('epiR', 'epi.nomogram.html')" style="text-decoration: underline; color: blue; cursor: hand">epi.nomogram</a>,<code><a href="ROC.html">ROC</a></code>
</p>
@@ -116,6 +116,6 @@
</script>
-<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.0 <a href="00Index.html">Index]</a></div>
+<hr><div align="center">[Package <em>DiagnosisMed</em> version 0.1.2.1 <a href="00Index.html">Index]</a></div>
</body></html>
Modified: pkg/DiagnosisMed/man/ROC.Rd
===================================================================
--- pkg/DiagnosisMed/man/ROC.Rd 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/man/ROC.Rd 2009-03-02 12:00:59 UTC (rev 6)
@@ -25,7 +25,7 @@
coded either as 0 - without target disease - or 1 - with the target disease;
or could be coded \link[base]{as.factor} with the words "negative" - without target disease - and
"positive" - with the target disease.}
- \item{test}{The index test or test under evaluation. A column in a dataframe or
+ \item{test}{The index test or test under evaluation. A column in a dataframe or vector
indicating the test results in a continuous scale. May also work with discrete
ordinal scale.}
\item{CL}{Confidence limit. The limits of the confidence interval. Must be coded
@@ -82,11 +82,15 @@
that behave like glucose (middle values are supposed to be normal and
extreme values are supposed to be abnormal) and immunefluorescence (lower
values - higher dilutions - are suppose to be abnormal) will not be correctly
- analyzed. In the latter example, multiplying the test results by -1 or other
+ analyzed. In the latter, multiplying the test results by -1 or other
transformation before analysis could make it work. The result table with the
- Print.full option, has more columns than can be shown in the screen. R
+ Print.full option, may have more columns than can be shown in the screen. R
automatically shows these columns below, therefore one has to be careful when
- relating the corresponding lines.
+ relating the corresponding lines. The AUC (area under the ROC curve) is estimated
+ by the trapezoidal method (also known as Mann-Whitney statistic), its confidence
+ interval is estimated by DeLong method. The validity measures such as
+ Sensitivity, Specificity and Likelihood ratios are estimated as
+ in \code{\link{diagnosis}} function.
Diagnostic odds ratio: \eqn{DOR = (TP*TN)/(FN*FP); the same as: DOR = PLR/NLR}
@@ -125,27 +129,28 @@
Greiner, M. (1996) Two-graph receiver operating characteristic (TG-ROC): update version supports optimisation of cut-off values that minimize overall misclassification costs. J.Immunol.Methods 191:93-94.
+Gengsheng Qin, Lejla Hotilovac. Comparison of non-parametric confidence intervals for the area under the ROC curve of a continuous-scale disagnostic test. Statistical Methods in Medical Research 2008; 17:207-221.
+
}
-\author{Pedro Brasil - \email{pedro.brasil at ipec.fiocruz.br}}
-\note{Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed R-Forge website \url{https://r-forge.r-project.org/projects/diagnosismed/}.
+\author{Pedro Brasil - \email{diagnosismed-list at lists.r-forge.r-project.org}}
+\note{Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed email list, or R-Forge website \url{https://r-forge.r-project.org/projects/diagnosismed/}.
}
-\seealso{\code{\link{diagnosis}},\code{\link{interact.ROC}},\link[PresenceAbsence]{optimal.thresholds},
- \link[epicalc]{roc.from.table},\link[ROCR]{prediction}}
+\seealso{\link[epitools]{binom.conf.int},\code{\link{diagnosis}},\code{\link{interact.ROC}},\link[ROCR]{performance}}
\examples{
# loading a dataset
data(tutorial)
-# attaching a dataset
+# The reference standard is not in the correct format.
+# Recoding the reference standard to "positive" & "negative" in a new variable.
+tutorial$Gold2<-as.factor(ifelse(tutorial$Gold=="pos","positive","negative"))
+# Attaching the data set with the modifications.
attach(tutorial)
-# The reference standard is not in the correct format
-# Recoding the reference standard to "positive" & "negative"
-tutorial$Gold2<-as.factor(ifelse(Gold=="pos","positive","negative"))
-# attaching the data set with the modifications
-attach(tutorial)
# A little description of the data set to check if it is ok!
str(tutorial)
-# Running ROC analysis with the standard options
-ROC(Gold2,Test_B)
+# Running ROC analysis with the full table option.
+ROC(Gold2,Test_B,Print.full=TRUE)
+# Adding a title to the graph.
+title(main="ROC graph")
}
\keyword{iplot}
\keyword{univar}
Modified: pkg/DiagnosisMed/man/diagnosis.Rd
===================================================================
--- pkg/DiagnosisMed/man/diagnosis.Rd 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/man/diagnosis.Rd 2009-03-02 12:00:59 UTC (rev 6)
@@ -81,10 +81,10 @@
Simel D, Samsa G, Matchar D (1991). Likelihood ratios with confidence: Sample size estimation for diagnostic test studies. Journal of Clinical Epidemiology 44: 763 - 770
}
-\author{Pedro Brasil - \email{pedro.brasil at ipec.fiocruz.br}}
-\note{Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed R-Forge website \url{https://r-forge.r-project.org/projects/diagnosismed/}.
+\author{Pedro Brasil - \email{diagnosismed-list at lists.r-forge.r-project.org}}
+\note{Bug reports, malfunctioning, or suggestions for further improvements or contributions can be sent, preferentially, through the DiagnosisMed email list, or R-Forge website \url{https://r-forge.r-project.org/projects/diagnosismed/}.
}
-\seealso{\code{\link{plot.diag}}, \link[epicalc]{ROC}, \link[epitools]{binom.conf.int},
+\seealso{\code{\link{plot.diag}}, \code{\link{ROC}}, \link[epitools]{binom.conf.int},
\link[epibasix]{sensSpec},\link[epiR]{epi.tests}}
\examples{
# Simulating a dataset
Modified: pkg/DiagnosisMed/man/interact.ROC.Rd
===================================================================
--- pkg/DiagnosisMed/man/interact.ROC.Rd 2008-10-10 14:54:17 UTC (rev 5)
+++ pkg/DiagnosisMed/man/interact.ROC.Rd 2009-03-02 12:00:59 UTC (rev 6)
@@ -31,18 +31,30 @@
[TRUNCATED]
To get the complete diff run:
svnlook diff /svnroot/diagnosismed -r 6
More information about the Diagnosismed-commits
mailing list