edits.seer.internal.rules.IFN6114.xml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of validation-edits-seer Show documentation
Show all versions of validation-edits-seer Show documentation
Java implemenation of the SEER edits.
The newest version!
<rule id="IFN6114" name="Number of Cores Positive/Examined, Prostate (NAACCR)" tag="N6114" java-path="lines.line" category="inter-field" depends="Year_of_Diagnosis"> <expression><![CDATA[if (line.dateOfDiagnosisYear == null || line.dateOfDiagnosisYear < '2019' || line.schemaId != '00580') return true if ((line.numberOfCoresPositive == null || line.numberOfCoresPositive == 'X8') && (line.numberOfCoresExamined == null || line.numberOfCoresExamined == 'X8')) return true if (line.numberOfCoresPositive == 'X7' || line.numberOfCoresExamined == 'X7') return line.numberOfCoresPositive == 'X7' && line.numberOfCoresExamined == 'X7' if (Functions.matches(line.numberOfCoresExamined, /^0[1-9]|[1-9]\d$/)) { if (line.numberOfCoresPositive == 'X6') return true else if (Functions.matches(line.numberOfCoresPositive, /^\d\d$/) && line.numberOfCoresExamined >= line.numberOfCoresPositive) return true return false } if (Functions.matches(line.numberOfCoresExamined, /^X[16]$/) && !Functions.matches(line.numberOfCoresPositive, /^\d\d|X[16]$/)) return false if (Functions.matches(line.numberOfCoresPositive, /^\d\d|X[16]$/) && line.numberOfCoresExamined == 'X9') return false return true]]></expression> <message>Number of Cores Positive conflicts with Number of Cores Examined.</message> <description><![CDATA[This edit verifies that the Number of Cores Positive and Number of Cores Examined SSDIs are coded consistently with each other. 1. The edit is skipped for the following conditions: a. Date of Diagnosis before 2019, blank (unknown), or invalid. b. Schema ID is not 00580 c. Number of Cores Positive and Number of Cores Examined are both blank or not applicable. 2. If Number of Cores Positive = X7 (no needle core biopsy performed), then Number of Cores Examined must = X7 (no needle core biopsy performed). 3. If Number of Cores Examined = X7 (no needle core biopsy performed), then Number of Cores Positive must = X7 (no needle core biopsy performed). 4. If Number of Cores Examined = 01-99 then Number of Cores Positive must = 00-99 and less than or equal to number of cores examined, or X6 (Biopsy cores positive number unknown). 5. If Number of Cores Examined = X1 (100 or more cores examined) or X6 (Biopsy cores examined, number unknown), then Number of Cores Positive must = 00-99 (number of positive cores), X1 (100 or more cores positive), or X6 (biopsy cores positive, number unknown). 6. If Number of Cores Positive = 00, 01-99, X1 or X6, then Number of Cores Examined must not equal X9.]]></description> <history> <event version="SE18-019-01" user="kirbyk" date="2019-03-29" ref="68158">Edit created.</event> <event version="SE18-020-05" user="kirbyk" date="2020-08-05" ref="68434">Added conditions for when Number of Cores Examined is not = X7.</event> <event version="SE23-023-01" user="shearerw" date="2023-02-24" ref="69201">Added conditions for when Number of Cores Examined is = X9.</event> <event version="SE24-024-01" user="kirbyk" date="2024-02-06" ref="69340">X9 removed as allowable value for Number of Cores Positive when Number of Cores Examined specified.</event> </history> </rule>