* SPSS syntax to generate: * CFSR Item III) Post-Investigation Services Provided, Unique Child Victims. * Syntax applies to NCANDS Child File V4.0. ************************************************************************************. ****** Lines beginning with '*' are comments and are not executed by SPSS. *****. ****** Name of State Master File must be entered in highlighted section below. *****. ************************************************************************************. * Fields MAL1LEV MAL2LEV MAL3LEV MAL4LEV and MALDEATH are used to identify maltreatment victims. * Non-victims are removed from the analysis. * 26 service fields are used to identify victims who received services. **********************************************************************************. ********** Enter name of the State Master File in following command line *********. get file = 'ENTER STATE FILE NAME HERE' * Create flag variable FLVICTIM to identify maltreatment victims. * If any of the maltreatment dispositions (MALLEV)are 1=sub or 2=ind, or 3=alt-resp victim * The child was a victim. * If the child died as result of the maltreatment MALDEATH=1, the child was a victim. compute flvictim = 0 . if (mal1lev le 3) flvictim = 1. if (mal2lev le 3) flvictim = 1. if (mal3lev le 3) flvictim = 1. if (mal4lev le 3) flvictim = 1. if (maldeath eq 1) flvictim = 1. * Analysis does not include non-victims and they are removed from the file. select if (flvictim eq 1) . * Set flag indicating whether services were provided. * Coding of any service to '1'='yes' results in the coding of '1'='yes' for this flag. * Start by redefining all service field codes as '1'='yes' or '0'='not yes'. recode postserv famsup fampres fostercr juvpet cochrep adopt casemang counsel daycare educatn employ famplan health homebase housing transliv inforef legal menthlth pregpar respite ssdisabl ssdelinq subabuse transprt othersv (1=1) (else = 0). * Initialize flag variable FLAGSERV to hold the count of all services provided. compute flagserv = postserv + famsup + fampres + fostercr + juvpet + cochrep + adopt + casemang + counsel + daycare + educatn + employ + famplan + health + homebase + housing + transliv + inforef + legal + menthlth + pregpar + respite + ssdisabl + ssdelinq + subabuse + transprt + othersv . * Collapse total count of services in FLAGSERV to a count of '1'='yes' if any services. if (flagserv ge 1) flagserv = 1. var labels flagserv 'Victim Received Post-Investigation Services' . val labels flagserv 1 'Yes' 0 'No' . * Active file currently holds records for duplicate victims. * File of unique victims is created by selecting one record per victim. * If any records for the victim indicate that services were provided, then * this should be reflected in the single record. * SORT command groups records in order by Child ID and then by FLAGSERV in descending order. * The inclusion of FLAGSERV in the sort command ensures that the first record will * hold FLAGSERV = 1 if any record for the child holds FLAGSERV = 1. sort cases by chid (a) flagserv (d) . * Select only the first record for each victim. * Syntax means, 'select if current record is not the same child as identified in * previous record (i.e., a new child)'. select if (chid ne lag(chid)) . * Current file now holds records for unique victims. * Counts displayed are counts of unique victims by receipt of services. freq flagserv.