org.apache.ctakes.smokingstatus.patientLevel
Class PatientLevelSmokingStatus
java.lang.Object
org.apache.ctakes.smokingstatus.patientLevel.PatientLevelSmokingStatus
public class PatientLevelSmokingStatus
- extends java.lang.Object
Patient-level smoking status classification used for the AMIA 2009 paper
From PatientLevelSmokingStatus_Jan09.java revised frequency based except for assigning past smoker
if exists only past and non-smoker
- Author:
- Mayo Clinic
Method Summary |
static void |
assignPatientLevelSmokingStatus()
performs the patient-level smoking status classification based on document-level classification
each patient is assigned only one final smoking status
RULE:
If exists only U assign U
Else if exist N and there is no PCS assign N
Else if exist S and there is no PC assign S
Else if exist P or C (can be both)
If exists either P or C assign P or C respectively
Else if exist both P and C
If(C freq >= P freq) assign C
Else assign P |
static void |
collectCounts(java.lang.String delim)
|
static void |
main(java.lang.String[] args)
|
static void |
printToFile()
|
void |
setInputFile(java.lang.String fileName)
|
void |
setOutputFile(java.lang.String fileName)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PatientLevelSmokingStatus
public PatientLevelSmokingStatus()
main
public static void main(java.lang.String[] args)
setInputFile
public void setInputFile(java.lang.String fileName)
setOutputFile
public void setOutputFile(java.lang.String fileName)
collectCounts
public static void collectCounts(java.lang.String delim)
assignPatientLevelSmokingStatus
public static void assignPatientLevelSmokingStatus()
- performs the patient-level smoking status classification based on document-level classification
each patient is assigned only one final smoking status
RULE:
If exists only U assign U
Else if exist N and there is no PCS assign N
Else if exist S and there is no PC assign S
Else if exist P or C (can be both)
If exists either P or C assign P or C respectively
Else if exist both P and C
If(C freq >= P freq) assign C
Else assign P
printToFile
public static void printToFile()