Teach you how to analyze ROC curve with SPSS

ROC curve is also called receiver operating curve. It was originally used in military radars and later widely used in medical statistics. The ROC curve is a curve drawn based on a series of different binary classification methods (cutoff value or decision threshold), with the true positive rate (sensitivity) as the ordinate and the false positive rate (1-specificity) as the abscissa.
The ROC curve is mainly used for binary outcomes, such as death, disease diagnosis, tumor recurrence, etc. It can be used to determine the cutoff point when the independent variable is a continuous variable.
Insert picture description here
There are many softwares that can do ROC curve, such as SPSS, R language, Stata, SAS, etc. Among them, SPSS is very simple and suitable for beginners who have no foundation at all. Today we will use SPSS to make a ROC curve that conforms to the publication of the paper.
First open SPSS, import one of our previous data of pneumonia and inflammatory factors,
Insert picture description here
and click Analysis ---- Classification ------ ROC curve
Insert picture description here
as shown below. Put the dependent variable pneumonia into the state variable, fill in the value of the occurrence, I Here is 1, the independent variables are put in the column of test variables, and the continuous variables are put in.
Insert picture description here
Click OK to get the following picture. The SPSS has reached 26.0 and the drawing is a little better than before. The pictures made in the previous version are really unreadable. The picture is slightly modified
Insert picture description here
, and it looks a little more beautiful after the modification. The
Insert picture description here
table below shows the AUC value of each indicator, which represents the ability of each indicator to determine pneumonia. This is an important indicator.
Insert picture description here
Next, we will find the specificity and sensitivity. , We take the inflammation index THF as a demonstration, the others are the same.
First, find its curve coordinates and
Insert picture description here
see that the two lines of sensitivity and 1-specificity are not. We copied it and put it in SPSS, and
Insert picture description here
got two new ones. Indicators VAR00001, WAR00002
Insert picture description here
use SPSS calculation function V=VAR00001-WAR00002, as shown in the figure below, the maximum value of the red line V is the cut-off point of TNF,
Insert picture description here
Insert picture description here
Therefore, the cut-off point of TNF is 48, the sensitivity is 46%, and the specificity=1-0.18=82%. Similarly, the cut-off point, sensitivity and specificity of other indicators can be obtained. Have you learned it?
Insert picture description here

Guess you like

Origin blog.csdn.net/dege857/article/details/112058852