* SPSS syntax to generate: * CFSR Item VII) Maltreatment in Foster Care, * Unique Child Victims 12 Months of the Reporting Period. * * Syntax File Name: C:\NCANDS\SPSS_CFSR\CFSR_VII_UNQCHLD_12m.SPS . * Instructions: Select 'Run All' after loading, no modification to syntax required. * Location of Report Produced: Reference SPSS output window after execution has completed. ********************************************************************************************. * Summary of Syntax Distributed In Conjunction with NCANDS FY 2005 Data Validation System. * * CREATE MASTER DATA FILE syntax creates file in SPSS format. * Must be run before all other syntax. * 'C:\NCANDS\datasys\dcdc\2005\[staterr]\full\create_master_sav_fy2005.sps * CFSR INDIVIDUAL COMPONENTS syntax generates counts/percentages for specific cells. * Execute only after creating master data file (see above). Produces reports for all counties. * Advantage of cell by cell syntax is that is more easily converted to other platforms * and is most suitable for editing to obtain custom reports. * c:\ncands\spss_cfsr\cfsr_[report item]_[unit of analysis].sps ************************************************************************************. * COMPUTATIONS DO NOT DERIVE COUNT OF CHILDREN IN FOSTER CARE PROVIDED FROM AFCARS. * Field CHID (Child ID) used to identify unique victims. * Field SUBYR is used to identify the calendar year associated with the Master File. * Fields MAL1LEV MAL2LEV MAL3LEV MAL4LEV and MALDEATH * are used to identify maltreatment victims. * Non-victims are removed from the analysis. * Field RPTDT (report date) is used to identify date when maltreatment was reported. * Fields PER1REL, PER2REL, and PER3REL are used to identify perpetrators who were * foster care providers: '3'='Relative Foster Parent'; '4'='Non-Relative Foster Parent'; '5' ='Residential Facility Staff' * '33' = Foster Parent, Relationship Unknown' . **********************************************************************************. ********** Enter name of the State Master File in following command line *********. get file = 'C:\NCANDS\datasys\dcdc\2005\[staterr]\full\masterv1.sav'. * freq per1rel per2rel per3rel. **** SPECIFY DATES FOR 12-MONTH REPORTING PERIOD. **** FOR CFSR VII, REPORTING PERIOD IS DEFINED WITH RESPECT TO REPORT DATE. ****************************************************************************************************************************** * Select records with report dates falling within 12 months reporting period. select if (rptdt ge strtdate). * Active file now holds only records for children victimized in the 12 months reporting period. * Remove non-victims from active file. * Create flag variable outcomev to identify maltreatment victims. * If any maltreatment disposition codes (MALLEV) are 1=sub,2=ind, * the child was a victim. * If the child died as result of the maltreatment MALDEATH=1, * the child was a victim. compute outcomev = 0 . if (mal1lev le 2) outcomev = 1. if (mal2lev le 2) outcomev = 1. if (mal3lev le 2) outcomev = 1. if (mal4lev le 2) outcomev = 1. if (maldeath eq 1) outcomev = 1. * Active file current holds all duplicate children of current year. * Analysis does not include non-victims and they are removed from the file, below. select if (outcomev eq 1) . * After select, above, active file holds all duplicate victims During Period Selected. * Set flags for FOSTPRNT and RESFACIL indicating whether child was victimized * by a relative foster parent (PERREL = 3), non-relative foster parent (PERREL = 4), * residential facility staff (PERREL =5), or foster parent (PERREL = 33). compute rltvprnt = 0 . if (per1rel = 3 ) rltvprnt = 1. if (per2rel = 3 ) rltvprnt = 1. if (per3rel = 3 ) rltvprnt = 1. var labels rltvprnt 'Child Victimized by Relative Foster Parent During Selected Period' . value labels rltvprnt 1 'Yes' 0 'No' . compute nrelprnt = 0. if (per1rel = 4 ) nrelprnt = 1. if (per2rel = 4 ) nrelprnt = 1. if (per3rel = 4 ) nrelprnt = 1. var labels nrelprnt 'Child Victimized by Non-Relative Foster Parent During Selected Period' . value labels nrelprnt 1 'Yes' 0 'No' . compute resfacil = 0 . if (per1rel = 5 ) resfacil = 1. if (per2rel = 5 ) resfacil = 1. if (per3rel = 5 ) resfacil = 1. var labels resfacil 'Child Victimized by Residential Facility Staff During Period Selected' . value labels resfacil 1 'Yes' 0 'No' . *freq rltvprnt nrelprnt resfacil. compute fostprnt = 0. if (per1rel eq 33) fostprnt= 1. if (per2rel eq 33) fostprnt = 1. if (per3rel eq 33) fostprnt = 1. var labels fostprnt 'Child Victimized by Foster Parent During Period Selected'. value labels fostprnt 1 'Yes' 0 'No' . * If child was victimized by a relative foster parent (RLTVPRNT=1), a non-relative foster * parent (NRELPRNT=1), or a residential facility staff (RESFACIL = 1), then the child * should be flagged as victimized in foster care. compute fostvict = 0. if (rltvprnt eq 1 or nrelprnt eq 1 or resfacil eq 1 or fostprnt eq 1) fostvict = 1. var labels fostvict 'Child Victimized in Foster Care During Period Selected' . value labels fostvict 1 'Yes' 0 'No' . select if fostvict = 1. exec. * Create record for each unique child from the current active file * which may contain multiple records/reports for the same child. * Setting the break variable to CHID ensures one record will be created * for each unique child. In addition, the use of the 'max' option * ensures that if a child was victimized by a foster care provider in * one report but not another, the value retained will be '1' indicating * that the child was maltreated by a foster care provider in at least * one report over this period. sort cases by chid (a) fostvict (d) rptdt (a). aggregate outfile = 'c:\tempfil2.sav' /break = chid / staterr = first(staterr) / rptcnty = first(rptcnty) / rltvprnt = max(rltvprnt) / nrelprnt = max(nrelprnt) / resfacil = max(resfacil) / fostprnt = max(fostprnt) / fostvict = max(fostvict) . * File just created holding records for unique victims must be retrieved. get file = 'c:\tempfil2.sav' . * Retrieve census data to permit generation of report for all counties. sort cases by staterr. recode rptcnty (sys$mis = 9999) . compute cntyfips = rptcnty. sort cases by staterr cntyfips. match files file = * /table = 'c:\ncands\census\county_fips.sav' /by = staterr cntyfips. * Identify missing county codes when referenced by CNTYNAME. if (rptcnty lt 999) cntyname = concat(' ',substr(cntyname,1,23)). if (rptcnty eq 999) cntyname = 'Out of State'. if (rptcnty eq 9999) cntyname = 'Not Reported'. if (cntyname eq ' ') cntyname = 'FIPS Code Invalid'. * Generate selected statistics by county. * Following command provides counts of unique victims maltreated by foster parent FOSTPRNT, a relative foster * parent RLTVPRNT, nonrelative foster parent NRELPRNT, or residential facility * staff RESFACIL. crosstabs tables cntyname by fostprnt rltvprnt nrelprnt resfacil fostvict by staterr /cells = count row. * Counts of children NOT maltreated in foster care are derived by subtracting NCANDS count of children maltreated * by foster care providers from AFCARS count of children placed in foster care. * To save a list of unique victims maltreated by foster care providers within 12 months of the reporting period * execute the command below. save outfile = 'c:\ncands\unique_victims_foster_12m.sav'. get file = 'c:\ncands\unique_victims_foster_12m.sav'.