/****************************************************************** READ_PPS678.SAS - file to read raw PPS6 (1989), PPS7 (1990), and PPS8 (1991) data files. Roughly based on read_pps.sas, the program from the medical school. Uses zone decimal informats. -Elaine Oct 24, 1994 ** Note that pps6 only goes to w23 rather than w30 ; ********************************************************************/ libname out '/disk/usr106/pps/data/sas'; filename pps6 pipe 'zcat /disk/usr106/pps/data/raw/pps6.Z'; filename pps7 pipe 'zcat /disk/usr106/pps/data/raw/pps7.Z'; *filename pps7 '/usr1/provdata/pps/pps7'; filename pps8 pipe 'zcat /disk/usr106/pps/data/raw/pps8.Z'; *option obs = 75; options ls=75; %macro years(input, output); data out.&output.; infile &input. lrecl=5211 missover; input @1 f1 $charzb6. @91 f16 $charzb36. @182 @1 provno $charzb6. @91 provname $charzb36. @128 paysys $charzb1. @134 (begdate enddate) (5.0) @144 (months control) (2.0) type $charzb1. @165 f29 zd6. @187 ssa 2.0 @198 status $charzb1. @201 cenreg 1.0 @249 totbeds zd9. @330 (f54-f73) (zd9.) @510 (f74-f81) (zd9.) @582 f82 zd9. @591 f82a zd9. @600 f82b zd9. @609 (f83-f84) (zd9.) @627 f84a zd9. @636 f84b zd9. @645 f84c zd9. @645 (f85-f86) (zd9.) @672 f86a zd9. @681 (f87-f88) (zd9.) @699 f88a zd9. @708 f88b zd9. @717 f88c zd9. @726 (f89-f444) (zd9.) @4038 (f449-f473) (zd9.) @4263 f473A zd9. @4272 f473B zd9. @4281 f473C zd9. @4290 f474 zd9. @4299 f474A zd9. @4308 f474B zd9. @4317 f474C zd9. @4326 (f475-f477) (zd9.) @4353 f478a zd9. @4362 (f479-f487) (zd9.) @4452 (f488-f499) (zd9.) @4686 (f507-f530) (zd9.) @4902 f530a zd9. @4911 (f531-f533) (zd9.) @4938 (w1-w30) (zd9.) ; f29 = f29/1000000; /*to insert the decimal point*/ capreduc = f29; mroudays = f54; msbdays = f55; micudays = f56; mccudays = f57; mocudays = f58; miphdays = f59; mipfdays = f60; troudays = f67; tsbdays = f68; ticudays = f69; tccudays = f70; tosudays = f71; hipdays = f72; fipdays = f73; bfcaps = f90; mecaps = f91; tdirsal = f101; otdirs = f111; physremu = f112; physadj = f119; aibfcaps = f120; atbfcaps = f121; aimecaps = f122; atmecaps = f123; treimbs = f138; tipcaps = f181; ttcaps = f182; trous = f183; ticus = f184; tccus = f185; totsus = f186; tsubprs = f187; tnursers = f188; tsnfs = f189; ticfs = f190; totcfs = f191; tors = f192; trecovrs = f193; tdelivrs = f194; tanesths = f195; tdiarads = f196; ttherads = f197; tradiois = f198; tlabs = f199; tbloods = f200; tbloodas = f201; tivs = f202; trespths = f203; tphysths = f204; toccuths = f205; tspeechs = f206; tecgs = f207; teegs = f208; tsupplys = f209; tdrugs = f210; tdialyss = f211; totancis = f212; tclinics = f213; temergs = f214; totouts = f215; totreims = f216; tspccs = f217; tnoreims = f218; cfadjust = f219; negcost = f220; tcaps = f221; rous = f222; icus = f223; ccus = f224; otsus = f225; subprs = f226; nursers = f227; snfs = f228; icfs = f229; otcfs = f230; ors = f231; recovrs = f232; delivrs = f233; anesths = f234; diarads = f235; therads = f236; radiois = f237; labs = f238; pbplabs = f239; bloods = f240; bloodas = f241; ivs = f242; respths = f243; respadjs = f244; physths = f245; physadjs = f246; occuths = f247; speechs = f248; ecgs = f249; eegs = f250; supplys = f251; drugs = f252; dialyss = f253; otancis = f254; clinics = f255; emergs = f256; otouts = f257; otreims = f258; totals = f259; spccs = f260; noreims = f261; negcost = f262; tfacils = f221; org = f264; recovrg = f265; delivrg = f266; anesthg = f267; diaradg = f268; theradg = f269; radioig = f270; labg = f271; pbplabg = f272; bloodg = f273; bloodag = f274; ivg = f275; respthg = f276; physthg = f277; occuthg = f278; speechg = f279; ecgg = f280; eegg = f281; supplyg = f282; drugg = f283; dialysg = f284; otancig = f285; clinicg = f286; emergg = f287; otoutg = f288; otreimg = f289; totalg = f290; morg = f291; mrecovrg = f292; mdelivrg = f293; manesthg = f294; mdiaradg = f295; mtheradg = f296; mradioig = f297; mlabg = f298; mpbplabg = f299; mbloodg = f300; mbloodag = f301; mivg = f302; mrespthg = f303; mphysthg = f304; moccuthg = f305; mspeechg = f306; mecgg = f307; meegg = f308; msupplyg = f309; mdrugg = f310; mdialysg = f311; motancig = f312; mclinicg = f313; memergg = f314; motoutg = f315; motreimg = f316; mtotalg = f317; mors = f318; mrecovrs = f319; mdelivrs = f320; manesths = f321; mdiarads = f322; mtherads = f323; mradiois = f324; mlabs = f325; mpbplabs = f326; mbloods = f327; mbloodas = f328; mivs = f329; mrespths = f330; mphysths = f331; moccuths = f332; mspeechs = f333; mecgs = f334; meegs = f335; msupplys = f336; mdrugs = f337; mdialyss = f338; motancis = f339; mclinics = f340; memergs = f341; motouts = f342; motreims = f343; mtotals = f344; krous = f345; kicus = f346; kccus = f347; kotsus = f348; ksubprs = f349; knursers = f350; kors = f351; krecovrs = f352; kdelivrs = f353; kanesths = f354; kdiarads = f355; ktherads = f356; kradiois = f357; klabs = f358; kbloods = f359; kbloodas = f360; kivs = f361; krespths = f362; kphysths = f363; koccuths = f364; kspeechs = f365; kecgs = f366; keegs = f367; ksupplys = f368; kdrugs = f369; kdialyss = f370; kotancis = f371; kclinics = f372; kemergs = f373; kotouts = f374; kotreims = f375; ktotals = f376; edsubprs = f413; ednurses = f414; edteducs= f440; outpatg = f444; mrous = f452; micus = f453; mccus = f454; mosus = f455; minpancs = f456; mmalprs = f457; opertots = f458; malpracs = f461; kidnacqs = f462; kidnerev = f463; drgpric = f470; drgoutl = f471; rousvcpt = f473; roucappt = f473A; roumept = f473B; rouanept = f473C; ancsvcpt = f474; anccappt = f474A; ancmept = f474B; ancanept = f474C; organacs = f475; teachmds = f476; educadj = f477; gradpaym = f478; dsadjust = f479; highesrd = f480; amtdue= f488; seqadjus = f489; label cenreg = "Census Region" begdate = "Beg. of Cost Reporting Period" enddate = "End of Cost Reporting Period" totbeds = "Total # of beds in the hospital" capreduc = "Inpat Capital Reduction Rate" mroudays = "Medicare Routine Care Days (excluding swing-bed)" f54 = "Medicare Routine Days (excluding swing-bed)" msbdays = "Medicare Swing Bed Days" f55= "Medicare Swing Bed Days" micudays = "Medicare ICU Days" f56 = "Medicare Intensive Care Unit Days" mccudays = "Medicare CCU Days" f57 = "Medicare Coronary Care Unit Days" mocudays = "Other Medicare Special Unit Days" f58 = "Other Medicare Special Care Unit Days" miphdays = "Medicare Inpat Days: Hospital" f59 = "Medicare Inpat Days--Hospital Total" mipfdays = "Medicare Inpat Days: Facility" f60 = "Medicare Inpat Days--Facility Total" f61 = "Medicaid Routine Days (excluding swing-bed)" f62 = "Medicaid Swing Bed Days" f63 = "Medicaid Intensive Care Unit Days" f64 = "Medicaid Coronary Care Unit Days" f65 = "Other Medicaid Special Care Unit Days" f66 = "Medicaid Inpat Days--Hospital Total" troudays = "Total routine care days (excl. s-bed)" f67 = "Total routine care days (excl. s-bed)" tsbdays = "Total swing bed days" f68 = "Total swing bed days" ticudays = "Total ICU days" f69 = "Total Intensive Care Unit days" tccudays = "Total CCU days" f70 = "Total Coronary Care Unit days" tosudays = "Total Other Special Care Unit Days" f71= "Total Other Special Care Unit Days" hipdays = "Hosp. inpat days: all-patient total" f72 = "Inpatient Days, All Patients--Hospital Total" fipdays = "Facility inpat days: all-patient total" f73 = "Inpatient Days, All Patients--Facility Total" f74 = "Full-Time Interns and Residents--Hospital Total" f75 = "Full-Time Interns and Residents--Facility Total" f76 = "Net Full-Time Interns and Residents--Hospital Total" f77 = "Net Full-Time Interns and Residents--Facility Total" f78 = "Average Number of Employees--Hospital Total" f79 = "Average Number of Employees--Facility Total" f80 = "Average Number of Nonpaid Workers--Hospital Total" f81 = "Average Number of Nonpaid Workers--Facility Total" f82 = "Medicare Discharges--Hospital Total (Including Swing Bed SNF)" f82a= "Medicare Discharges--Swing Bed SNF (See Note 7)" f82b= "Medicare Discharges--Hospital Total (Excluding Swing Bed SNF)" f83 = "Medicare Discharges--Facility Total" f84 = "Medicaid Discharges--Hospital Total (Including Swing Bed SNF and Swing Bed ICF)" f84a= "Medicaid Discharges--Swing Bed SNF" f84b= "Medicaid Discharges--Swing Bed ICF" f84c= "Medicaid Discharges--Hospital Total (Excluding Swing Bed SNF and Swing Bed ICF)" f85 = "Medicaid Discharges--Facility Total" f86 = "Medicaid Discharges (Medicaid Elig.)--Hospital Total" f86a= "Medicaid Discharges (Medicaid Elig.)--Swing Bed SNF" f87 = "Medicaid Discharges (Medicaid Elig.)--Facility Total" f88 = "Total Discharges--Hospital Total (Including Swing Bed SNF and Swing Bed ICF" f88a= "Total Discharges, All Patients, Swing Bed SNF" f88b= "Total Discharges, All Patients, Swing Bed ICF" f88c= "Total Discharges--Hospital Total (Excluding Swing Bed SNF and Swing Bed ICF" f89 = "Total Discharges, All Patients, Facility Total" bfcaps = "Cap-related costs: bldg & fixtures" mecaps = "Cap-related costs: moveable equipt" tdirsal = "direct salaries- Total" otdirs = "other direct costs - total" physremu = "Physicians' Remuneration: total" physadj = "Adjustment for Physicians' prof. svcs" aibfcaps = "Adj'd inpat bldg & fix K-related costs" atbfcaps = "Adj'd total bldg & fix K-related costs" aimecaps = "Adj'd inpat mvbl equipt K-rel'd costs" atmecaps = "Adj'd total mvbl equipt K-rel'd costs" treimbs = "Total Reimbursable Costs" tipcaps ="TCRPTCost inpat directly assgnd K costs" ttcaps = "TCRPTCost total directly assgnd K costs" trous = "TCRPTCost Routine Care" ticus = "TCRPTCost ICU Care" tccus = "TCRPTCost CCU Care" totsus = "TCRPTCost Other Special Care Units" tsubprs = "TCRPTCost Sub-provider total" tnursers = "TCRPTCost Nursery" tsnfs = "TCRPTCost Skilled Nursing Facility" ticfs = "TCRPTCost intermediate care facility" totcfs = "TCRPTCost Other Care Facility" tors = "TCRPTCost Operating Room" trecovrs = "TCRPTCost Recovery Room" tdelivrs = "TCRPTCost Delivery and Labor Room" tanesths = "TCRPTCost Anesthesiology" tlabs = "TCRPTCost Laboratory" tbloods = "TCRPTCost whole blood & packed RBCs" tbloodas = "TCRPTCost blood admin (stor proc transf)" tivs = "TCRPTCost intravenous therapy" trespths = "TCRPTCost respiratory therapy" tphysths = "TCRPTCost physical therapy" toccuths = "TCRPTCost occupational therapy" tspeechs = "TCRPTCost speech pathology" tecgs = "TCRPTCost electrocardiology" teegs = "TCRPTCost electroencephalography" tsupplys = "TCRPTCost medical supplies chgd to pat" tdrugs = "TCRPTCost drugs chgd to patient" tdialyss = "TCRPTCost renal dialysis" totancis = "TCRPTCost other inpat ancillary" tclinics = "TCRPTCost outpatient clinic" temergs = "TCRPTCost emergency" totouts = "TCRPTCost other outpatient services" totreims = "TCRPTCost other reimbursable" tspccs = "TCRPTCost all special purpose cost ctrs" tnoreims = "TCRPTCost nonreimbursable " cfadjust = "TCRPTCost crossfoot adjustment" negcost = "TCRPTCost negative cost ctrs" tcaps = "TCRPTCost total K-related" rous = "TCostAA Routine Care" icus = "TCostAA ICU Care" ccus = "TCostAA CCU Care" otsus = "TCostAA Other Special Care Units" tsubprs = "TCostAA Sub-provider total" nursers = "TCostAA Nursery" snfs = "TCostAA Skilled Nursing Facility" icfs = "TCostAA intermediate care facility" otcfs = "TCostAA Other Care Facility" ors = "TCostAA Operating Room" recovrs = "TCostAA Recovery Room" delivrs = "TCostAA Delivery and Labor Room" anesths = "TCostAA Anesthesiology" labs = "TCostAA Laboratory" pbplabs = "TCostAA PBP Clinic lab svcs- prgm only" bloods = "TCostAA whole blood & packed RBCs" bloodas = "TCostAA blood admin (stor proc transf)" ivs = "TCostAA intravenous therapy" respths = "TCostAA respiratory therapy" respadjs = "TCostAA respiratory therapy adjustment" physths = "TCostAA physical therapy" physadjs = "TCostAA physical therapy adjustment" occuths = "TCostAA occupational therapy" speechs = "TCostAA speech pathology" ecgs = "TCostAA electrocardiology" eegs = "TCostAA electroencephalography" supplys = "TCostAA medical supplies chgd to pat" drugs = "TCostAA drugs chgd to patient" dialyss = "TCostAA renal dialysis" otancis = "TCostAA other inpat ancillary" clinics = "TCostAA outpatient clinic" emergs = "TCostAA emergency" otouts = "TCostAA other outpatient services" otreims = "TCostAA other reimbursable" totals = "TCostAA total facility after step-down" spccs = "TCostAA all special purpose cost ctrs" noreims = "TCostAA nonreimbursable " negcost = "TCostAA negative cost ctrs" tfacils = "TCostAA total facility costs" org = "TFAChg Operating Room" recovrg = "TFAChg Recovery Room" delivrg = "TFAChg Delivery and Labor Room" anesthg = " TFAChg Anesthesiology" labg = "TFAChg Laboratory" pbplabg = "TFAChg PBP Clinic lab svcs- prgm only" bloodg = "TFAChg whole blood & packed RBCs" bloodag = "TFAChg blood admin (stor proc transf)" ivg = "TFAChg intravenous therapy" respthg = "TFAChg respiratory therapy" physthg = "TFAChg physical therapy" occuthg = "TFAChg occupational therapy" speechg = "TFAChg speech pathology" ecgg = "TFAChg electrocardiology" eegg = "TFAChg electroencephalography" supplyg = "TFAChg medical supplies chgd to pat" drugg = "TFAChg drugs chgd to patient" dialysg = "TFAChg renal dialysis" otancig = "TFAChg other inpat ancillary" clinicg = "TFAChg outpatient clinic" emergg = "TFAChg emergency" otoutg = "TFAChg other outpatient services" otreimg = "TFAChg other reimbursable" totalg = "TFAChg total Charges- all cost centers" morg = "MCAIHACh Operating Room" mrecovrg = "MCAIHACh Recovery Room" mdelivrg = "MCAIHACh Delivery and Labor Room" manesthg = "MCAIHACh Anesthesiology" mlabg = "MCAIHACh Laboratory" mpbplabg = "MCAIHACh PBP Clinic lab svcs- prgm only" mbloodg = "MCAIHACh whole blood & packed RBCs" mbloodag = "MCAIHACh blood admin (stor proc transf)" mivg = "MCAIHACh intravenous therapy" mrespthg = "MCAIHACh respiratory therapy" mphysthg = "MCAIHACh physical therapy" moccuthg = "MCAIHACh occupational therapy" mspeechg = "MCAIHACh speech pathology" mecgg = "MCAIHACh electrocardiology" meegg = "MCAIHACh electroencephalography" msupplyg = "MCAIHACh medical supplies chgd to pat" mdrugg = "MCAIHACh drugs chgd to patient" mdialysg = "MCAIHACh renal dialysis" motancig = "MCAIHACh other inpat ancillary" mclinicg = "MCAIHACh outpatient clinic" memergg = "MCAIHACh emergency" motoutg = "MCAIHACh other outpatient services" motreimg = "MCAIHACh other reimbursable" mtotalg = "MCAIHACh total inpat hospital chgs" mors = "MCAIHACo Operating Room" mrecovrs = "MCAIHACo Recovery Room" mdelivrs = "MCAIHACo Delivery and Labor Room" manesths = "MCAIHACo Anesthesiology" mlabs = "MCAIHACo Laboratory" mpbplabs = "MCAIHACo PBP Clinic lab svcs- prgm only" mbloods = "MCAIHACo whole blood & packed RBCs" mbloodas = "MCAIHACo blood admin (stor proc transf)" mivs = "MCAIHACo intravenous therapy" mrespths = "MCAIHACo respiratory therapy" mphysths = "MCAIHACo physical therapy" moccuths = "MCAIHACo occupational therapy" mspeechs = "MCAIHACo speech pathology" mecgs = "MCAIHACo electrocardiology" meegs = "MCAIHACo electroencephalography" msupplys = "MCAIHACo medical supplies chgd to pat" mdrugs = "MCAIHACo drugs chgd to patient" mdialyss = "MCAIHACo renal dialysis" motancis = "MCAIHACo other inpat ancillary" mclinics = "MCAIHACo outpatient clinic" memergs = "MCAIHACo emergency" motouts = "MCAIHACo other outpatient services" motreims = "MCAIHACo other reimbursable" mtotals = "MCAIHACo total inpat ancillary costs" krous = "MCIHKRPT Routine Care" kicus = "MCIHKRPT ICU Care" kccus = "MCIHKRPT CCU Care" kotsus = "MCIHKRPT Other Special Care Units" ksubprs = "MCIHKRPT Sub-provider total" knursers = "MCIHKRPT Nursery" kors = "MCIHKRPT Operating Room" krecovrs = "MCIHKRPT Recovery Room" kdelivrs = "MCIHKRPT Delivery and Labor Room" kanesths = "MCIHKRPT Anesthesiology" klabs = "MCIHKRPT Laboratory" kbloods = "MCIHKRPT whole blood & packed RBCs" kbloodas = "MCIHKRPT blood admin (stor proc transf)" kivs = "MCIHKRPT intravenous therapy" krespths = "MCIHKRPT respiratory therapy" kphysths = "MCIHKRPT physical therapy" koccuths = "MCIHKRPT occupational therapy" kspeechs = "MCIHKRPT speech pathology" kecgs = "MCIHKRPT electrocardiology" keegs = "MCIHKRPT electroencephalography" ksupplys = "MCIHKRPT medical supplies chgd to pat" kdrugs = "MCIHKRPT drugs chgd to patient" kdialyss = "MCIHKRPT renal dialysis" kotancis = "MCIHKRPT other inpat ancillary" kclinics = "MCIHKRPT outpatient clinic" kemergs = "MCIHKRPT emergency" kotouts = "MCIHKRPT other outpatient services" kotreims = "MCIHKRPT other reimbursable" ktotals = "MCIHKRPT total facility after step-down" edsubprs = "Med. educ. subprovider pass-thru" ednurses = "Med. educ. Nursery pass-thru" edteducs= "Total hospital Med. educ. pass-thru" opertots = "Total Medicare inpat Operating Costs" malpracs = "Malpractice Insurance Costs" kidnacqs = "Direct Kidney Acquisition Costs" kidnerev = "Revenues for kidneys sold" drgpric = "DRG payments-- other than outliers" drgoutl = "DRG outlier payments" educadj = "Indirect Medical Educ. Adjust." gradpaym ="Direct Graduate Medical Payment" dsadjust = "Disproportionate Share Adjustment" highesrd = "Addt'l payments for high ESRD use" amtdue = "Amt. due provider, before sequestration" seqadjus = "Sequestration adjustment" outpatg = "Total Outpatient Charges" rousvcpt = "(Summary) Routine Svc Pass Thru Costs" roucappt = "(Summary) Routine capital Pass Thru Csts" roumept = "(Summary) Routine med ed pass thru costs" rouanept = "(Summary) Routine non-MD anesth. pt cst" ancsvcpt = "(Summary) Anclry. svc. pass-thru costs" ancmept = "(Summary) Anclry. med ed pass-thru costs" anccappt = "(Summary) Anclry. capital pt costs" ancanept = "(Summary) Anclry. non-MD anesth. pt cst" organacs = "(Summary) organ acquisition costs" teachmds = "(Summary) cost of teaching physicians" mrous = "(Summary) Medicare Routine Service Cost" micus = "(Summary) Medicare ICU total cost" mccus = "(Summary) Medicare CCU total cost" mosus = "(Summary) Medicare other SU total cost" minpancs = "(Summary) Medicare inpat anclry cost" mmalprs = "(Summary) Medicare malpractice cost" end; *drop f54-f60 f67-f73 f90 f91 f101 f111 f112 f119-f123 f138 f181-f376 f413 f414 f440 f444 f452 f453 f454 f455 f456 f457 f458 f461-f463 f470 f471 f477-f480 f488 f489 f29 f473 f473A f473B f473C f474 f474A f474B f474C f475 f476; run; proc print data = out.&output. (obs = 25); title 'sample data from &output.'; run; %mend years; %years(pps6, pps89); %years(pps7, pps90); %years(pps8, pps91);