Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Info |  Source |  Entry Points
Print Page as PDF
Routine: ICDJC1

Package: DRG Grouper

Routine: ICDJC1


Information

ICDJC1 ;ALB/ARH - DRG GROUPER CALCULATOR 2015 - ATTRIBUTES ;05/26/2016

Source Information

Source file <ICDJC1.m>

Entry Points

Name Comments DBIA/ICR reference
PRATT(ICDPR,ICDDATE,PRARR) ; get all attributes of Procedures - determine if event is Surgical or Medical and MDCs
; returns array with the Procedure Attributes only, later updated to include Cluster Attributes
DXATT(ICDDX,ICDDATE,ICDEXP,DXARR) ; get all attributes of Diagnosis - determine if MCC or CC apply to event and MDCs
; returns array with the Diagnosis Attributes only, later updated to include updates due to HAC
; the diagnosis event MDCs are determined by the primary Dx, based on the MDCs of its assigned code sets
; event MCC/CC is determined by secondary Dxs and the primary Dx if it is an MCC/CC of its Own
; the MCC/CC of a secondary Dx may be applied to the event DRG unless overridden by one of two cases:
; PDX is a member of the secondarys exclusion group or if patient has expired and MCC only if Alive
GETATT(TYP,CDIFN,DATE) ; get one codes Attributes for date, either diagnosis (83.5,10) or procedure (83.6,10) or cluster (83.61,10)
; only one set of attributes may be active on a given date, returns entire node
; input: TYP - type of codes 'DX' or 'PR' or 'CL', CDIFN - ptr to code in 83.5 or 83.6 or 83.61
; output: node of codes attributes active on date, if any, 83.5,10 or 83.6,10 or 86.61,10
GETMDC(TYP,ICDARR,ICDDATE) ; get list of all MDC's the diagnosis/procedure codes are assigned to
; compile list of MDC's based on the codes assigned code sets (83.5,20&83.6,20), Primary Dx and OR Procedures only
; input: TYP - type of codes 'DX' or 'PR', ICDARR is either diagnoais ICDDX or procedures ICDPRC
; output: returns list of codes MDC ID's - 00;03... for Primary DX or all OR Procedures only
GETEVT(DXARR) ; get the events MCC/CC attribute, compiled from all diagnosis attributes
; check each dx for an MCC/CC that was not overridden and still applies, MCC highest priority then CC
; input: DXARR list of each diagnosis attributes
; output: returns either MCC or CC or blank as the event attribute
EXCLD(DX,EXCLGRP,DATE) ; determine if the Diagnosis is in the Exclusion group
; if primary Dx is member of a secondary Dxs Exclusion group then that secondary Dx can not impart MCC/CC to event
; input: DX - ptr to 80, EXCLGRP - 4 character Exclusion Group ID (83.51, .01 and 83.5,10,.03)
; output: returns true if PDx is in SDx Exclusion group (83.51) on date and secondary Dxs MCC/CC should be ignored
DXHAC(ICDDX,ICDPR,ICDDATE,ICDPOA,DXARR) ; reset DXATT for HAC, determine HAC for each Dx not POA (N,U), if found then re-set event MCC/CC
; identify any diagnosis defined as a HAC, if a Dx is HAC then its MCC/CC should be ignored
; a HAC applies only to diagnosis Not Present on Admission (N or U)
; if a Dx is Not Present on Admission (N,U) and a member of a HAC group then it can not impart MCC/CC to the event
; if the HAC group requires multiple Dx codes then the MCC/CC of all are screened out
;
; Input: ICDDX(x) and ICDPR(x) - array of Dx/procedures input to API, ICDDATE - date of event
; ICDPOA(x) - array of Dx POA input to API
; DXARR(x) - dx ifn ^ MCC/CC ^ exclude grp ^ alive exclude ^ (reserved HAC) ^ ^ MCC/CC applies
; Output: DXARR - 'MCC' or 'CC' or blank, updated for any HAC Dx found
; DXARR(x) - (dx ifn) ^ (MCC/CC) ^ (exclude grp) ^ (alive exclude) ^ HAC Grp ^ ^ MCC/CC applies
; - if Dx is a member of a HAC group then 'HAC Grp' is set and 'MCC/CC applies' is updated
; to remove the Dxs MCC/CC from the event
HACSET(ICDDX,ICDPR,ICDDATE,ICDPOA,HCSARR) ; get all HAC Code Sets defined by event Diagnosis and Procedure codes
; a HAC only applies if Dx was not present on admission (N,U) and possibly only to secondary or primary Dx
; input: ICDDX(x) and ICDPR(x) - array of Dx/procedures input to API, ICDDATE - date of event
; ICDPOA(x) - array of Dx POA input to API
; output: returns array of all HAC code sets applicable to the specific event
; HCSARR( hac code set (83.71), "DX", x - code entry in ICDDX ) = ""
; HCSARR( hac code set (83.71), "PR", x - code entry in ICDPR ) = ""
GETCDH(TYP,CDIFN,DATE,ARRHSX) ; get HAC code sets for a single code on a date, either diagnosis (83.5,30) or procedure (83.6,30)
; input: TYP - type of codes 'DX' or 'PR', CDIFN - ptr to code in 83.5 or 83.6
; output: ARRHSX - array of HAC code sets the Code is a member of on the date
; ARRHSX(hac code set ifn (83.71)) = CDIFN
PRCLS(ICDPR,ICDDATE,PRARR) ; reset PRATT for Clusters, determine Cluster OR/NOR attribute for each event Procedure, if found then re-set event OR/NOR
; identify all active clusters satified by the event procedures, set all cluster procedures OR/NOR to the Clusters OR/NOR
; the cluster identified is an indicator and not definitive, each procedure may be assigned to multiple clusters
; assumes that all clusters a procedure is a member of is the same type, either all OR clusters or all NOR clusters
Info |  Source |  Entry Points