Epi Info Guide
Epi Info Guide
Guide
Data Management and Analysis
A PLACE Manual
Guide for
Using Epi Info Software
This guide was made possible by support from the U.S. Agency for
International Development (USAID) under terms of Cooperative
Agreement GPO-A-00-03-00003-00. The authors views expressed
in this publication do not necessarily reflect the views of USAID or
the United States Government.
November 2005
Introduction
This technical document provides information you will need to know in order to manage and
analyze the data collected during the PLACE assessment, as well as guidance in preparing the
data tables used in a PLACE report. It begins with step-by-step instructions for preparing
customized data entry screens in Epi Info for each questionnaire, so that data from the
Community Informant Questionnaire (Form A), the Venue Verification Form (Form C), and the
Questionnaire for Individuals Socializing at Venues (Form D) can be entered, stored, and
analyzed in Epi Info. (The Venue and Event Report [Form B] does not require the use of Epi
Info.) Instructions are also provided for modifying or creating a simple checking program to
ensure that values entered during data entry fall within the parameters of allowed response
codes. Lastly, instructions are provided to help you prepare the data and perform the analysis
necessary to complete a PLACE report, which will summarize the PLACE findings in your
priority prevention areas.
This document is presented in the same sequence of data management and analysis activities that
are used in a PLACE study. Each of the four sections begins with a summary of the instructions
that will follow. A flow chart illustrating the sequence of steps from preparing for data entry
through the end of data analysis (Sections 1-3) is provided on the next page in Figure 1. The
chart indicates which steps are covered within each of the first three sections of this document.
Section 4, the final section, provides data use exercises. The two appendices provide information
about Epi Info coding and commands.
Epi Info is a public domain software package developed by the U.S. Centers for Disease Control
and Prevention (CDC). Designed for the global community of public health practitioners and
researchers, it provides tools for easy form and database construction, data entry, and analysis
with epidemiologic statistics, maps, and graphs. The software can be downloaded from the CDC
Web site at: http://www.cdc.gov/epiinfo/.
This publication was written for Epi Info Version 6, which was the most current DOS version at
time of publication. The instructions will also work with Epi Info Version 3.3.2, a Windowsbased version that was released in 2005. A complete manual for Version 6 can be accessed at the
CDC Web site at: http://www.cdc.gov/epiinfo/Epi6/ei6manl.htm. Tutorials on how to use Epi
Info are also available at CDC, at: http://www.cdc.gov/epiinfo/tutorials.htm.
System requirements for using Epi Info for Windows are as follows: Windows 98, NT 4.0, 2000,
or XP is required; 32 MB of RAM (64 MB for Windows 4.0 and 2000, 128 MB for Windows
XP); 200 megahertz processor is recommended, 300 megahertz recommended for Windows XP;
and at least 260 megabytes of free hard disk space to install, 130 megabytes after installation.
Figure 1
Section 1:
Section 2:
Data entry
Merge records
Print frequencies
Visually check
printout
Section 3:
Does data need
to be cleaned?
YES
Finalize cleaning
program
Run cleaning
program
Finalize analysis
program
Run analysis
program
NO
Table of Contents
SECTION 1: Preparing for Data Entry.......................................................................... 1
How to Use This Module ........................................................................................ 1
Modifying or Creating a Questionnaire Date Entry Screen ............................ 4
Data Entry Exercise: Understanding Data Entry Screen Programming ........ 7
Data Entry Exercise: Modifying Data Entry Screens ........................................ 8
Setting Check Parameters for Data Entry........................................................ 11
Date Entry Exercise: Using the Check Entry Program Window ..................... 13
SECTION 2: Data Entry....................................................................................................15
Entering Data ....................................................................................................... 15
Merging Files......................................................................................................... 15
SECTION 3: Data Analysis..............................................................................................17
Producing Frequency Tables ............................................................................. 17
Data Analysis Exercise: Creating a Text File .................................................... 19
Cleaning Data and Outputting a New Data Set ........................................... 20
Instructions for Data Analysis ............................................................................. 21
SECTION 4: Data Use Exercies.................................................................................. 27
Data Use Exercise: Documenting the PPA Selection Process ..................... 27
Data Use Exercise: Understanding PLACE Questionnaires........................... 29
Data Use Exercise: Understanding PLACE Questionnaire Legal Values .... 30
Data Use Exercise: Understanding Data Cleaning ....................................... 31
Data Use Exercise: Cleaning Data in Epi Info ................................................ 32
Data Use Exercise: Creating New Variables in Epi Info ................................ 33
Data Use Exercise: Filling in the PLACE Report Template Tables................. 36
APPENDIX: Epi Info Code ..............................................................................................37
Questionnaire Data Entry Screens .................................................................... 37
Check Files for Data Entry ............................................................................... 45
Cleaning Programs.............................................................................................. 65
Analysis Programs for the PLACE report template tables ............................ 71
SECTION 1:
This section provides instruction in modifying Epi Info questionnaire data entry
screens to reflect changes made to PLACE questionnaires when they were
adapted for use in your priority prevention areas (PPAs). It also provides
instruction for editing Epi Info check programs for each data entry screen,
programs that prevent invalid responses from being recorded during data entry.
Epi Info Version 6 is a series of microcomputer programs for handling epidemiologic data in
questionnaire format and for organizing study designs and results into text that may form part of
written reports. A questionnaire can be set up and processed in a few minutes, but Epi Info also
can form the basis for a powerful disease surveillance system database with many files and
record types. It includes features used by epidemiologists in statistical programs, such as SAS or
SPSS, and database programs like dBASE. Unlike commercial programs, however, Epi Info may
be freely copied and given to friends and colleagues.
Epi Info allows rapid setup of new entry forms and data files, easily
customized data entry, and many data management and analysis
techniques.
The instructions in this section are based on a learning module from the Northern Health
Information Partnership and the Ontario Ministry of Health, Canada. Learning objectives are as
follows:
You will be able to create a questionnaire using the Epi Info word processor.
You will be able to save a questionnaire.
You will be able to retrieve a questionnaire for editing.
You will be able to enter data into a record file.
You will be able to set parameters to aid in the valid entry of data (i.e., to be able
to set upper and lower ranges, legal values).
You will be able to merge two files.
How to Use This Module
In many of the examples that follow, you will encounter text in BOLD. This indicates text
displayed by EpiInfo or what should be typed into EipInfo. For example, C:>cd\epi6 means
that cd\epi6 should be typed. Bold text is also used to indicate keys on your keyboard to be
used during the execution of a step (e.g. press F9 or press Enter.) This module is intended
only to help the user become familiar with Epi Info Version 6. It is not intended to be a complete
manual. (The complete manual is available at: http://www.cdc.gov/epiinfo/Epi6/ei6manl.htm.)
Table 1.1
Questionnaire or
Form
Questionnaire
Data Entry Files
Data Entry
Record Files
Data Entry
Check Files
Cleaning
Programs
PLACE
Report
Analysis
Programs
CI.QES
CI.REC
CI.CHK
CI_C.PRG
CI.PRG
Not applicable
Not applicable
Not applicable
Not applicable
Not applicable
Venue Verification
Form (Form C)
VENU.QES
VENU.REC
VENU.CHK
VENU_C.PRG
VENU.PRG
Questionnaire For
Individuals
Socializing
at Venues (Form D)
SOCIAL.QES
SOCIAL.REC
Community
Informant
Questionnaire
(Form A)
Venue and Event
Report (Form B)
Each of the files above is located in the PLACE CD in the Epi Info section that also contains this
document (located in the folder on this CD called EpiInfo). There are no Epi Info files for the
Venue and Event Report (Form B) because data from Form B will only need to be entered into
an Excel spreadsheet. The Epi Info data entry and check files and the cleaning and analysis
programs for each of the three questionnaires are provided in the appendix of this document.
Getting Started
Double click on the Epi Info icon on
your desktop or open the program as
you usually do. As you enter the
program you will see the following:
If you highlight PROGRAMS (appearing in green in the illustration), you will see the
following choices:
EPED word processor: This is a word processor and is used to create questionnaires for the
purpose of inputting data.
ENTER data: This part of the program allows you to enter data to a .REC file (or data file). It
also allows you to revise the data even after they are entered.
ANALYSIS of data: This allows you to tabulate your data, produce frequencies, means,
standard deviations, etc.. It also allows you to run some basic statistical tests on the data such as
chi-squares, odds ratio, relative risks, ANOVA and stratified analysis.
CHECK customize entry: This allows you to set upper and lower ranges, legal values,
automatic coding, etc. which acts as a built-in check and minimizes data entry errors.
IMPORT files: This selection allows you to bring in data from other programs or in other
formats such as dBASE, Lotus, ASCII
EXPORT files: This allows you to export data from an Epi Info data file to a file format for
other software. Most computer programs will accept at least one of the supported formats.
MERGE files: Allow you to combine data files and update previous records
STATCALC calculator: Calculates statistics from table values that you enter directly from the
keyboard.
CSAMPLE analyze surveys: Calculates weighted analysis of population surveys (such as the
Ontario Health Survey).
EPITABLE calculator: This part of the program allows you to compare means, calculate
known chisquare, compare proportions, etc.
VALIDATE duplicate entry: This is used to compare two Epi Info files entered by different
operators and reports any differences.
Notes: To increase the screen size, select ANALYSIS from the Programs Menu. The Epi Info
screen size will increase to fill your computer screen. Return to the Main Menu by
pressing F10.
File names can only be up to eight characters long in Epi Info Version 6. Epi Info will be
unable to open a file if it has a name longer than eight characters.
Epi Info uses the first eight digits of a variable name unless you define the variable name using
curly brackets { }. In the example below, we have defined the variable names so they are
standard across all studies. All of the answers in this questionnaire are numbers. Each #
symbol represents one digit. Where there are two #symbols, two digits can be entered. In the
event that you have a questionnaire that requires letters to be input, you use the symbol _ (an
underline key stroke). As before, each underline _ you put in represents one character.
An example of a questionnaire and corresponding Epi Info .QES file is given below.
COMMUNITY INFORMANT QUESTIONNAIRE
No.
Questions
A1
A2
A3
Coding categories
<Name of priority prevention area>
Interviewer Number
A.
B.
A4
Date (DD/MM/YY)
A5
(DAY) ___ ___ / (MONTH) ___ ___ /(YEAR) ___ ___ ___ ___
MALE 1
FEMALE 2
In the example above, you can see that up to 999 Priority prevention area codes can be entered,
and up to 99 interview locations are possible. Question A3 has two parts, an interviewer number
and a community informant number. As you can see, the code for the Epi Info data entry screen
refers to these parts as separate variables: A3A and A3B. A3A can be two two digits long and
A3B can be three digits long. The date of interview (A4) allows two digits for date and month
and four digits for year. Question A5, the gender of community informant, can be either 1 for
male or 2 for female; one digit only is included, indicated by the fact that there is only one #
mark. Each of these parameters can be edited, as you will learn below.
Other examples of Epi Info data entry field types are described in Table 1.2, below:
Table 1.2
Example
Field Type
Explanation
ADDRESS
_________________
(Shift underline)
Text
For every dash you will be allowed one character (or letter),
any character can be entered.
AGE ## or
AGE ##.#
Numeric
Fields
Name <A>
Upper Case
Field
DogBite <Y>
Date
<MM/DD/YY>
or
Date
<DD/MM/YY>
or
Date <DD/MM>
Phone
<Phonenum>
Date Fields
MALE 1
Gender of respondent
FEMALE 2
C15
PATRON 2
OTHER 3
C16
A.
B.
YES, WILLING 1
NO, NOT WILLING 2
YES 1
NO BECAUSE:
NO WILLING RESPONDENT 2
Exercise Answers: The answers below are from the Epi Info questionnaire data entry screen for
the Venue Verification form.
{C14} Gender of respondent #
{C15} Position at venue #
{C16A} How old are you? ##
{C16B} Are you willing to answer these questions? #
{C17} Was an interview initiated? #
As you can see, a space is left between each new questionnaire number. For question C16, there
are two parts; no space is left between these two items, indicating that they are part of the same
question. Every question has only one # mark except for C16A. That is because a response of
only one digit is required for each question except for How old are you? were assuming
that the informants interviewed during venue verification will be younger than 100 years old.
The complete text for the Epi Info data entry screens for each of the three questionnaires is
provided in Appendix 1 of this document.
Data Entry Exercise: Modifying Data Entry Screens
Computer Exercise: Each questionnaire that interviewers use in your PLACE study will be
modified from the version provided on the PLACE CD in Microsoft Word. Obviously, a data
manager must make corresponding changes in the corresponding Epi Info data entry screen for
each questionnaire so that the questionnaire seen on screen in Epi Info during data entry matches
the questionnaire used in the field by interviewers. Each questionnaire has questions that will be
modified, as locally appropriate. For some questions, the names of local PPAs and districts need
to be inserted. For others, categories may need to be added, as indicated. Lastly, if your PLACE
assessment didnt include the tuberculosis (TB) or injection drug use (IDU) modules in Form D
(optional questions D62-D69), then you will need to remove the TB and IDU module questions
from the data entry screen file for this form in Epi Info (SOCIAL.QES) and update the
corresponding .REC file.
Note: Once you have modified the .QES file and updated the .REC file, you will
also need to edit the .CHK file!
In this exercise, you will work through some of the modifications that may need to be made in
the data entry screen for the Questionnaire for Individuals Socializing at Venues (Form D), as an
example.
First, lets look at question D51 in the form (forms are available on the CD and are reproduced in
the manual under the Forms tab). This question will need to be modified to include additional
locally important types of health education programs, if any, and to remove the line that says
<OTHER LOCALLY APPROPRIATE>.
No.
Questions
D51
We want to know
whether you have
heard or been to any
health education
programs. In the past
three months, have
you
Coding categories
YES
NO
G.
The data entry screen in Epi Info for this question will initially look something like this:
We would like to modify the data entry screen to either remove the D51G line, or to change it
to a local health education program that should be included. If, in your PPA, for example, there
is a street theater program that you want to include as a health education program, you might
want to replace <OTHER LOCALLY APPROPRIATE> with Watched HIV/AIDS Street
Theater Performance?
Under the Programs menu, highlight EPED word processor and press
Enter.
Select F2, and select Open File This Window.
You will be asked to enter the location and file name of the questionnaire
that you want to work with. If the questionnaire is on your CD drive E,
for example, and you want to edit the Questionnaire for Individuals
Socializing at Venues, you would type: E:\EPIINFO\SOCIAL.QES
and press enter.
Enter any changes you want to make to the questionnaire:
Delete D51G Other locally appropriate # and type D51G Watched
HIV/AIDS Street Theater Performance? #. This indicates that you are
adding a locally appropriate category to question D51; the new variable
name is D51G.
Press F10 when you are finished.
You will see: Leaving program. Do you want to save recent work
(Y/N)? To save the changes you have made, press Y; your changes will be
saved and you will be returned to the main Epi Info menu.
Now, view the data entry screen for this questionnaire to make sure you have made the modifications as
you wanted. Because you have changed the questionnaire data entry screen, you must update the .REC
file used for entering data. To do this,
Select the Programs menu from the main Epi Info menu, highlight Enter Data
and press Enter.
You will get the following menu:
Type
E:\EPIINFO\SOCIAL.REC.
This is the .rec file to be
created.
E:\EPIINFO\SOCIAL.REC
E:\EPI INFO\SOCIAL.QES
10
When the program asks for Questionnaire file (.QES), type in the name and
location of the questionnaire file that you just revised:
E:\EPIINFO\SOCIAL.QES and press Enter.
Choose Y and press Enter. A red box will appear with the text,
Overwrite EXISTING C:\EPIINFO\SOCIAL.REC with new file?
(Y/N/<Esc>). Press Y to overwrite the .REC file with the new version of
the questionnaire data entry screen that you just created.
A new data entry screen will appear it should look like this:
11
Note: If you have modified the .QES file and updated the .REC file, you will also
need to edit the .CHK file (data entry checking program)!
Epi Infos Check customize entry program assigns an acceptable range or list of values to every
question on the data entry screen. Use of this program is an important way to increase accuracy
during data entry. It will catch typo errors that occur when an invalid response value is entered.
For example, if a question has only two possible answers, 1 or 2, you would set up the check
program only to accept these values. Then, if the values 3, 11, 22, or 9 are entered, Epi
Info will not accept them.
Warning: The check program will not prevent an incorrect value that is in the
acceptable range from being entered!
Instructions for accessing the Check customize entry program are provided below. As an
example, you will view the customized entry program for the Questionnaire for Individuals
Socializing at Venues (Form D).
Check Menu
Under the Programs menu, highlight Check customize entry and press
Enter.
You will get the following menu, which allows you to create a .CHK file
for a .REC file, or to edit a .CHK file already associated with a particular
.REC file. At this point, you will just be using the Check customize
entry program to look at the .CHK program [test] so that you can
understand how it works.
Type:
E:\EPIINFO\SOCIAL.REC
E:\EPIINFO\SOCIAL.REC
The computer will lead you to a screen that looks like the questionnaire
data entry screen. Grey boxes after each question indicate where data are
entered. You can move the cursor from box to box using the up and
down arrow keys on your computers keyboard.
Move the cursor to the grey box after question D1. You should see text at
the bottom of the screen that reads, D1: Integers allowed. Integers are
the only valid values for this field because, in the questionnaire data entry
form (E:\EPIINFO\SOCIAL.QES), ### was entered after question D1,
indicating that up to three integers could be entered it is therefore not
possible to enter any characters other than numerals.
Below, you will be asked to complete an exercise based on this check
program. Leave the Epi Info check program screen open, and read below
to complete Exercise 3.
Date Entry Exercise: Using the Check Entry Program Window
For this exercise, you will be using the Check Entry Program window for the Questionnaire for
Individuals Socializing at Venues (Form D) as a guide. Move the cursor from question to
question (using the up and down arrow keys on your keyboard) to determine the allowed values
for the variables listed below. Remember that the allowed values for the variable where your
cursor is positioned will be described at the bottom of the screen.
The answers are provided on the next page. Try to complete the exercise without looking at the
answers.
Note: The Check Entry Program window for the Questionnaire for Individuals
Socializing at Venues (Form D) is the screen that you opened following
the instructions above, under Check Menu.
Questions (write down your answers, then compare with answers on the next page):
1. List all the values allowed for the variable D3.
2. Why do you think those values are allowed?
3. List all the values allowed for the variable D26.
4. List all the values allowed for the variable D27.
5. List all the values allowed for the variable D46B.
13
Answers to Exercise 3:
1. List all the values allowed for the variable D3: All entries allowed.
2. Why do you think those values are allowed? Because for a venue name, you may need to
enter a mix of numbers and letters.
3. List all the values allowed for the variable D26: Valid values 1 to 8.
4. List all the values allowed for the variable D27: Valid values 1 to 2.
5. List all the values allowed for the variable D46B: Valid values 1, 2, and 9.
Check Menu Syntax
If, in your questionnaire, for the first question there are only four possible responses 1, 2, 3, and
4, you can program the appropriate field to accept only 1, 2, 3, and 4. This can be done two
ways. For example, presume the variable is called A1:
Method 1
Place your cursor in the space next to A1.
Type 1 and then press F1 (min).
In the same space, type 4 and then press F2 (max).
Press F10 to exit.
Write data to disk (Y/N)? Type Y.
Method 2
At A1, type 1 and press F6. Now type 2 and press F6, the same for C and
D. At the bottom of the screen you will see the following 1,2,3,4 This
means that only 1,2,3,4 will be allowed to be inputted into that field.
Press F10 to exit.
Write data to disk (Y/N)? Type Y.
Both of these methods are setting the minimum allowed value to 1 and the maximum allowed
value to 4. Anything from 1 to 4 will be allowed. Another other than that will not be allowed.
Deleting Parameters
What if you want to delete a set of parameters? Instead of 1, 2, 3, and 4, you want only 1, 2 and 3
as options:
Enter the check program as before.
Place the cursor on the variable you wish to edit.
press F9 (edit field).
You will get a different screen.
Move your cursor to the material you want to delete and then press delete.
If you only want values 1, 2, and 3, put your cursor over the 4 and press
delete. Then type 3 (if you used Method 1 to create the check program).
Type ESC to return to the original screen.
14
SECTION 2:
Data Entry
This section provides instructions for entering data using Epi Info data entry
screens, saving data that has been entered, and merging all of the questionnaire
records you have entered into one large .REC file for cleaning and analysis.
Entering Data
Under the Programs menu, highlight Enter Data and press Enter.
At data file (.REC): type the name of the file you wish to enter data into.
(This is the same procedure you went through to create the .REC file
before you could set parameters.) Press Enter.
Enter 1 since you have already created the .REC file, and press Enter.
Type Y at OK, and press Enter.
You can now start entering data into the .REC file.
As you enter the data you will note that the cursor will automatically move to the next variable
when you have entered the data for one field; otherwise the enter key or the down arrow key will
move the cursor to the next variable. The cursor can be moved back by pressing the up arrow
key.
To save the data, enter Y when you get to the end of the record.
Merging Files
Merging files can be useful if the data are entered on two different computers and then need to be
combined so that analysis can occur. The steps below illustrate how to merge data when all the
variable names within two .REC files are identical. For example, if you have entered data on two
different computers and therefore have two .REC files called TEST.REC and TEST2.REC,
you can create a new .REC file called TEST3.REC using the following instructions:
Under the Programs menu, highlight Merge data file and press Enter.
You will see the menu shown on the next page.
15
16
SECTION 3:
Data Analysis
This section provides step-by-step instructions for cleaning your data before
analysis and for the actual analysis of data collected in your PLACE survey.
First, you will be instructed to print a document with the frequencies of each
variable. This printout will enable you to determine whether you need to clean
your data to change invalid responses to missing data. (This wont be
necessary if you used the Epi Info Check Program!) Programs have been
provided for data cleaning, but before you can run these programs, you will need
to adapt them so that they match with any changes you made to the
questionnaire. Analysis programs are provided for you, as well, to save you time.
These programs instruct Epi Info to produce tables with all of the information
you will need to complete a PLACE report, using the PLACE report template
provided on the PLACE Manuals CD. Before you use these programs, you need
to edit them to reflect any changes to the questionnaires that you may have made
when you adapted them to your local setting. Lastly, instructions are provided for
running the analysis programs. After you run these programs, PLACE report
tables can be filled in with your results!
17
Getting Started
Open Epi Info. Under the Programs pull down menu, select ANALYSIS of data. An analysis
window will open. To read your data into Epi Info, after the EPI6> prompt at the bottom of the
screen type:
READ <pathway for file>.
For example, if your data set is called cidata.rec and is located in a directory called Data on your
hard drive (designated as the C drive on your computer), you would type:
READ C:\Data\cidata.rec.
If you do not remember where your files are located or the name of your file, type READ and
press enter. A pop-up window will appear. You current location is listed at the top of the box
(C:\EPI6\*.rec) and all .REC files in that directory are listed. Use the arrow keys to select your
file or directory and press Enter. To go to a high level folder, select the ..\ symbol in the top
left hand corner and press Enter.
Adjusting Your Settings
Turning off the statistics associated with the frequency output is helpful if you do not need all the
statistical analysis Epi Info can provide. To limit the output from Epi Info to the information that
will be useful to you to complete the tables, type:
SET statistics=off.
You can also include missing values in your frequency output. To make sure that all observations
are included in your tables (including those observations where the response is missing), type:
SET ignore=off.
Producing One-way Frequency Tables
To produce a frequency table for a variable in the selected data set, type:
FREQ <variable_name>.
For example, if you want to produce the frequency table for the type of community informant
variable, type:
FREQ A6.
Notice in your output that not all values for this variable are displayed. For example, if you did
not interview any traditional healers, there will not be a row in your table for the value of 25. To
produce a frequency table for all variables in your data set, a more efficient way to do this, is to
type:
18
FREQ *.
If you do not want to include a few variables in your output, then type:
FREQ * NOT var1.
For example, if you wanted to output all of the variables in your key informant data set except
the community informant number, then you would type:
FREQ * NOT A3B.
Writing Output to a Text File
To create a text file containing your output, type:
ROUTE filename.txt.
The output from all subsequent statements that are submitted will be written to a text file located
in the same directory as your data set. The filename you select can be no more that eight
characters long. To close the file and start writing output to your screen, type:
ROUTE screen.
For example, if you want to output one-way frequencies for all variables in your community
informant data set to a text file named ci_tabs.txt, you would type:
ROUTE ci_tabs.txt
FREQ *
ROUTE screen.
Data Analysis Exercise: Creating a Text File
For your community informant, venue verification, and socializing individuals data sets, create a
text file for each data set that contains the one-way frequencies of all variables in the data sets.
Remember your will need to READ in the data set, ROUTE the data to a text file, produce
FREQuency tables, and ROUTE the output back to the screen. Give the text file for each data set
a unique name.
After using the FREQ * command to create a printout of the frequency of every variable in your
data set, visually check the printout:
19
20
ROUTE cleanci.rec
WRITE recfile.
The above code creates a new .REC file named cleanci that contains your cleaned data with the
newly defined analysis variables.
Adapting the Provided Cleaning Programs
IMPORTANT! Epi Info has the capability to create programs that contain many lines of code
that can clean data and save it to a new data set. To save time, we created programs that clean the
variables for the community informant, venue verification, and socializing individuals data sets
(CI_C.PRG, VENU_C.PRG, and SOCIAL_C.PRG). The programs replace out-of-range data
with missing values. You will not need to run them if you used Epi Infos Check Program. The
programs also create new clean data sets after variables have been cleaned. Review the code for
each of these programs, found in the appendix of this document. Notice that you have learned
how to do all of the tasks included in the programs.
Before you can run these programs, you need to make sure that the programs are updated
according to changes made when each questionnaire was adapted for your local study. For
example, if an additional category was added to a variable, you want to make sure that value is
within the allowed range for that variable. Or, if you did not use the TB or IDU modules for
Form D, delete these lines from the cleaning program. It is very important to make sure the
program is correct for your data otherwise, you may end up replacing valid data with missing
values!
Make sure that the range check commands are correct for your data set. To make changes, open
the .PRG files in the Notepad program or another text editor and change as necessary.
Using the Provided Cleaning Programs
To run a program in Epi Info type:
RUN <filename.pgm>.
For example, to run the venue verification cleaning program from the PLACE CD (if the CD is
in your E drive) you type:
RUN E:\EPIINFO\VENU_C.PRG.
The program will ask you for the name of your unclean data set and then when it is finished
running will tell you that it created a clean data set named VENU_C.REC. Use this data set for
all future analysis of data.
Instructions for Data Analysis
21
22
READ A:\CI_C.REC.
The data file you selected can now be accessed for analysis. The next step is to specify the output
destination of the analyses performed. The default is the screen. To specify output to a document,
type ROUTE and the file path and name of the text file you wish to create. For example,
typing ROUTE C:\EPI6\SOCIAL.TXT will create the document SOCIAL.TXT in the
C:\EPI6 directory. Once the ROUTE command has been utilized, all output generated by the
Analysis of data program will be saved to that file. When you are finished writing to your text
file, type:
ROUTE SCREEN.
Selecting a Subset of Records for Analysis
If you want to subset your data to look at the characteristics of people in your data that meet
certain criteria, you can select only those records that fulfill a certain condition. For example, if
you are using the Community Informant Questionnaire (CI.REC), type:
SELECT A8=1.
The above statement tells Epi Info to include only individuals in the analysis who were willing to
answer the questionnaire (A8=1). These records will remain selected until you deselect them. To
deselect records, type:
SELECT
and press Enter.
If you want to select individuals based on more than one characteristic, then type:
SELECT A8=1 and A5=1.
The above statement tells Epi Info to include only male individuals (A5=1) in the analysis who
where willing to answer the questionnaire (A8=1).
Calculating Frequencies
To calculate a frequency, type:
FREQ <variable_name>.
Multiple variables names (up to 15) can be included per FREQ statement. They are listed
individually:
FREQ A5 A6 A7 A8.
Calculating a Mean, Median, or Sum
23
To calculate the mean, medina, or sum of a continuous variable, set the value of the statistics
function back to on. To turn the statistics on, type:
SET STATISTICS=ON.
Then at the bottom of the frequency output for the variable of interest will be the mean, median,
and sum values:
SET STATISTICS=ON
FREQ A8.
The above statements are used to produce the mean, median, and sum of A8 (age of respondent)
and other variables throughout the data analysis process.
Create a 2 X 2 Table to Look at Two Variables at Once
In the community informant data set, we have two variables gender of community informant
(A5) and willing to answer (A8). Consequently, we would like to construct a 2 X 2 table using
these variables.
At the epi6 prompt, type the following:
tables A5 A8
and press Enter.
This will produce a table, chi-square value, degrees of freedom, and probability value.
Note that if you press F3, you will get a list of variables. F2 will allow you to list all the
commands utilized by Epi Info
In most cases, the command is listed first followed by the variable names. For a list of
commands available in analysis, see the Epi Info manual available from CDC at:
http://www.cdc.gov/epiinfo/Epi6/ei6manl.htm.
Defining New Variables
A new variable can be created from an existing variable in one of several ways. Names of
variables in Epi Info can be no longer than eight characters. For example, if you want to recode
an age variable with values that range from 0 to 99, you would use the following code:
DEFINE ageg _ _ _ _ _
24
25
place, you will need to enter the venue identification numbers in the SELECT command so that
analyses will pertain only to those venues.
The program files will save all output to the C:\EPI6\ directory. If the project computer has the
Epi Info program saved somewhere else, the ROUTE command in the program will need to be
changed in a text editor. If you have named your data sets differently than CI.REC, VENU.REC,
and SOCIAL.REC, you will need to rename the data sets or change the program text to recognize
the actual data set names. (For example, if you created new, clean data sets named CI_C.REC,
VENU_C.REC, and SOCIAL_C.REC, then you will need to modify the programs to use these
different names when opening the data sets for analysis.)
The text for each program file is found in the appendix. You can edit the programs using
Notepad or Wordpad just open the Epi Info program that you want to edit from within either of
these two simple word processing programs. It is very important to make sure the programs are
updated with any changes made to questionnaires for your PLACE study otherwise, you may
end up with nonsensical results! If variable or data set names have been changed for your study,
for example, you must make sure that those changes are reflected in the analysis programs.
Instructions for Using Provided Analysis Programs
To run each file, type the name and filepath of the program:
RUN E:\EPIINFO\SOCIAL.PRG
You will see:
Enter the name and location of your dataset.
Then enter:
C:\SOCIAL.REC
if, for example, your data set is on your C drive.
The program files included with the PLACE manual contain the ROUTE command that is
necessary to specify the output destination and generate the PLACE summary reports. The
program files will save all output to the C:\EPI6\ directory (unless you have edited the program
files to direct output to another directory location).
26
SECTION 4:
28
29
Question Number
Legal Values
A6
C24A
1,2
30
31
Check your statements by finding the statement in the cleaning program that cleans the variable.
32
33
This code tells Epi Info to create a new variable called total that will be equal to the sum of
meet_new, sex_soc, idu_soc, sy_soc, mob_soc, and msm_soc.
For all the other variables that show where key populations are socializing, write out the new
variable names, the questionnaire items used to create the new variables, and the Epi Info code
that creates them. Fill in this information in the table below. The first row has been done for
you. (Answers are given on the next page.)
Table 4.3
Variable Description
Variable
Name
meet_new
Questionnaire Items
Used to Create
Variable
C22A, C22B
34
if (C22A=1 or
C22B=1) then
meet_new=1
else meet_new=0
Variable
Name
Questionnaire Items
Used to Create
Variable
meet_new
C22A, C22B
if (C22A=1 or C22B=1)
then meet_new=1
else meet_new=0
sex_sol
C22E
if C22E=1
then sex_sol=1
else sex_sol=0
idu_soc
C30K, C31K
if (C30K>0 or C31K>0)
then idu_soc=1
else idu_soc=0
sy_soc
if (C30D>0 or C30E>0 or
C31D>0 or C31E >0)
then sy_soc=1
else sy_soc=0
mob_soc
C30H, C31H
if (C30H>0 or C31H>0)
then mob_soc=1
else mob_soc=0
msm_soc
C31M
if C31M>0
then msm_soc=1
else msm_soc=0
total
meet_new, sex_sol,
idu_soc, sy_soc,
mob_soc, msm_soc
total=meet_new + sex_sol
+ idu_soc + sy_soc +
mob_soc + msm_soc
35
36
APPENDIX:
This appendix lists Epi Info code for each questionnaire data entry screen (.QES
files), each check file for data entry (.CHK files), each cleaning program and
each analysis program (.PRG files). In a number of places, this guide refers you
to these programs.
Providing the coding in printed form should help you to understand the logic and
meaning of the Epi Info code used in your PLACE study, as well as provide you
with an easy reference for determining what needs to be changed in your study
questionnaires, check programs, and cleaning and analysis programs.
Venues
Venues
Events
Events
37
{C21} Have you see used syringes lying around... in the past three months? #
{C22A} Do men meet new female sexual partners here? #
{C22B} Do women meet new sexual partners here? #
{C22C} Do men meet male (gay) sexual partners here? #
38
{C22D}
{C22E}
{C22F}
{C22G}
{C22H}
{C29A}
{C29B}
{C29C}
{C29D}
{C29E}
{C29F}
This PPA #
Elsewhere in district/province #
Other District/Province 1 #
Other District/Province 2 #
Elsewhere in Country #
Outside this Country #
{C30A}
{C30B}
{C30C}
{C30D}
{C30E}
{C30F}
{C30G}
{C30H}
{C30I}
{C30J}
{C30K}
{C30L}
Women
Women
Women
Women
Women
Women
Women
Women
Women
Women
Women
Women
{C31A}
{C31B}
{C31C}
{C31D}
{C31E}
{C31F}
{C31G}
{C31H}
{C31I}
{C31J}
{C31K}
{C31L}
{C31M}
Men
Men
Men
Men
Men
Men
Men
Men
Men
Men
Men
Men
Men
live in PPA #
are secondary or high school students #
are unemployed #
are university/college students #
are less than age 18 #
live within a 10-minute walk of here #
come here at least once a week #
are from outside this district/province #
drink alcohol here #
find a new sexual partner here #
appear to be injection drug users #
appear to be selling or buying sex #
live in PPA #
are secondary or high school students #
are unemployed #
are university/college students #
are less than age 18 #
live within a 10-minute walk of here #
come here at least once a week #
are from outside this district/province #
drink alcohol here #
find a new sexual partner here #
appear to be injection drug users #
appear to be selling or buying sex #
are men who have sex with men/gay/homosexual #
39
{C32A} Men... go to other locations to socialize and look for a new partner? #
{C32B} Women... other locations to socialize and look for a new partner? #
{C33A}
{C33B}
{C33C}
{C33D}
{C33E}
{C33F}
{C34A}
{C34B}
{C34C}
{C34D}
{C34E}
{C34F}
{C35A}
{C35B}
{C35C}
{C35D}
{C35E}
{C35F}
{C35G}
{C35H}
{C36} In the past year, how often have condoms been available here? #
{C37} Are there any condoms here today? #
{C38} In the past four weeks... any condoms been sold or taken freely? #
{C39} Is it possible to get a condom... at night? #
{C40} Willing to have some type of AIDS prevention program here? #
{C41} Would you be willing to sell condoms here? #
{C42A}
{C42B}
{C42C}
{C42D}
Number
Number
Number
Number
of
of
of
of
40
Socialize? #
Drink alcohol? #
Look for a sexual partner? #
Work at my job? #
41
{D30} Have you ever had sex with a person you first met here? #
{D31} When was the most recent time you met someone here... later had sex? #
{D32} The first time you had sex with this person, did you use a condom? #
{D33} TOTAL IN PAST 4 WEEKS: ##
{D34} 4 WEEK NEW: ##
{D35} 12 MONTH TOTAL: ##
{D36} 12 MONTH NEW: ##
{D37} Did you use a condom the first time... most recent new partner? #
{D38A} AGE OF YOUNGEST: ##
{D38B} AGE OF OLDEST: ##
{D39} SOCIALIZED AT THIS PLACE: ##
{D40A} In past year... sex with someone not living with or married to? #
{D40B} If yes, did you use a condom the last time you had sex... ? #
{D41A} In past year... sex with someone living with or married to? #
{D41B} If yes, did you use a condom the last time you had sex... ? #
{D42A} Have you ever had sex? #
{D42B} Age at first sex ##
{D43A} MEN: Pain on urination? #
{D43B} MEN: Unusual discharge? #
{D43C} MEN: Sores? #
{D44A}
{D44B}
{D44C}
{D44D}
{D44E}
MEN:
MEN:
MEN:
MEN:
MEN:
{D45} MEN: How many men... have you had sex with in the past 12 months? ##
{D46A} WOMEN: Lower abdominal pain? #
{D46B} WOMEN: Unusual discharge? #
{D46C} WOMEN: Sores? #
{D47A}
{D47B}
{D47C}
{D47D}
{D47E}
WOMEN:
WOMEN:
WOMEN:
WOMEN:
WOMEN:
{D48} Did you use a condom the last time you had sex? #
{D49A} Have you given or received money in exchange for sex... ? #
{D49B} IF YES, did you use a condom the last time money was given... ? #
{D50} Do you have a condom with you now? #
42
{D51A}
{D51B}
{D51C}
{D51D}
{D51E}
{D51F}
{D51G}
{D52A} Have you been tested in the past 12 months... or never tested? #
{D52B} Did you get your test results? #
{D53} Would you be interested in getting HIV test... next 12 months? #
{D54} Are you currently a student? #
{D55} What is the highest level of school you have completed? #
{D56} Are you currently employed... or... are you looking for work? #
{D57} Have you ever been married? #
{D58A} Are you currently married or living with a sexual partner? #
{D58B} How frequently do you use condoms with your spouse or live-in partner? #
{D59} In your opinion, do people who inject drugs socialize at this venue? #
{D60} Have you injected an addictive drug... in the past 12 months? #
{D61} When did you last inject drugs? #
Injection Drug Use Module
{D62} With whom do you usually inject drugs? #
{D63} Did you share a syringe the last time you injected drugs? #
{D64A}
{D64B}
{D64C}
{D64D}
Share a syringe #
Take drugs from a common reservoir #
Use read-made drug solution without boiling #
Exchange a used for a new syringe #
{D65A} TOTAL: ##
{D65B} NEW: ##
{D66} Can you get new syringes whenever you want? #
TB Module
{D67A}
{D67B}
{D67C}
{D67D}
{D67E}
{D67F}
{D67G}
43
Unemployment #
Violence #
Access to health care #
AIDS #
Alcohol abuse #
Lack of education #
Getting food to eat #
Injection drug abuse #
44
45
C15
RANGE 1 3
END
C16B
RANGE 1 2
END
C17
RANGE 1 3
END
C18
LEGAL
1
2
3
9
END
END
C20A
RANGE 1 2
END
C20B
RANGE 1 2
END
C20C
RANGE 1 2
END
C20D
RANGE 1 2
END
C20E
RANGE 1 2
END
C20F
RANGE 1 2
END
C20G
RANGE 1 2
END
C20H
RANGE 1 2
END
C20I
RANGE 1 2
END
C20J
RANGE 1 2
46
END
C20K
RANGE 1 2
END
C20L
RANGE 1 2
END
C21
RANGE 1 2
END
C22A
RANGE 1 2
END
C22B
RANGE 1 2
END
C22C
RANGE 1 2
END
C22D
RANGE 1 2
END
C22E
RANGE 1 2
END
C22F
RANGE 1 2
END
C22G
RANGE 1 2
END
C22H
RANGE 1 2
END
C23
RANGE 1 4
END
C24A
RANGE 1 2
END
C24B
RANGE 1 2
END
C24C
RANGE 1 2
47
END
C24D
RANGE 1 2
END
C24E
RANGE 1 2
END
C25A
RANGE 1 7
END
C25B
RANGE 1 4
END
C26A
LEGAL
11
22
33
44
55
66
77
END
END
C26B
LEGAL
11
22
33
44
END
END
C27
RANGE 1 14
END
C28A
LEGAL
1
2
4
6
9
15
19
20
END
END
C29A
RANGE 1 3
END
48
C29B
RANGE 1 3
END
C29C
RANGE 1 3
END
C29D
RANGE 1 3
END
C29E
RANGE 1 3
END
C29F
RANGE 1 3
END
C30A
RANGE 0 3
END
C30B
RANGE 0 3
END
C30C
RANGE 0 3
END
C30D
RANGE 0 3
END
C30E
RANGE 0 3
END
C30F
RANGE 0 3
END
C30G
RANGE 0 3
END
C30H
RANGE 0 3
END
C30I
RANGE 0 3
END
C30J
RANGE 0 3
END
49
C30K
RANGE 0 3
END
C30L
RANGE 0 3
END
C31A
RANGE 0 3
END
C31B
RANGE 0 3
END
C31C
RANGE 0 3
END
C31D
RANGE 0 3
END
C31E
RANGE 0 3
END
C31F
RANGE 0 3
END
C31G
RANGE 0 3
END
C31H
RANGE 0 3
END
C31I
RANGE 0 3
END
C31J
RANGE 0 3
END
C31K
RANGE 0 3
END
C31L
RANGE 0 3
END
C31M
RANGE 0 3
END
50
C32A
LEGAL
1
2
9
END
END
C32B
LEGAL
1
2
9
END
END
C33B
LEGAL
1
2
3
97
99
END
Jumps
1 C33D
2 C33D
97 C33D
99 C33D
END
END
C33D
RANGE 1 10
LEGAL
99
END
Jumps
1 C33F
2 C33F
3 C33F
4 C33F
5 C33F
6 C33F
7 C33F
8 C33F
9 C33F
99 C33F
END
END
C34B
LEGAL
1
2
3
97
99
END
Jumps
51
1 C34D
2 C34D
97 C34D
99 C34D
END
END
C34D
RANGE 1 10
LEGAL
99
END
Jumps
1 C34F
2 C34F
3 C34F
4 C34F
5 C34F
6 C34F
7 C34F
8 C34F
9 C34F
99 C34F
END
END
C35A
RANGE 1 2
END
C35B
RANGE 1 2
END
C35C
RANGE 1 2
END
C35D
RANGE 1 2
END
C35E
RANGE 1 2
END
C35F
RANGE 1 2
END
C35G
RANGE 1 2
END
C35H
RANGE 1 2
END
C36
RANGE 1 3
52
END
C37
RANGE 1 3
END
C38
RANGE 1 4
END
C39
LEGAL
1
2
8
END
END
C40
LEGAL
1
2
8
END
END
C41
LEGAL
1
2
3
9
END
END
Questionnaire for Individuals Socializing at Venues (Form D) Check File for Data Entry
File Location and Name: E:\EPIINFO\SOCIAL.CHK
D2B
RANGE 1 2
END
D6
53
D11
RANGE 1 2
END
D13
RANGE 1 5
END
D14
RANGE 1 2
END
D15A
RANGE 1 2
Jumps
1 D16
END
END
D16
RANGE 1 5
END
D17
RANGE 1 5
END
D18
RANGE 0 97
END
D19
RANGE 1 5
END
D20A
LEGAL
1
2
3
4
6
7
9
END
Jumps
7 D21A
9 D21A
END
END
D20B
54
3
4
6
7
9
END
Jumps
7 D22A
9 D22A
END
END
D21B
55
3
4
5
6
7
8
END
Jumps
8 D25
END
END
D24B
56
D32
LEGAL
1
2
9
END
END
D37
LEGAL
1
2
9
END
END
D39
RANGE 0 97
END
D40A
RANGE 1 2
END
D40B
LEGAL
1
2
9
END
END
D41A
RANGE 1 2
END
D41B
LEGAL
1
2
9
END
END
D42A
RANGE 1 2
END
D42B
RANGE 0 97
END
D43A
LEGAL
1
2
9
END
END
57
D43B
LEGAL
1
2
9
END
END
D43C
LEGAL
1
2
9
END
END
D44A
REPEAT
LEGAL
1
2
9
END
END
D44B
LEGAL
1
2
9
END
END
D44C
LEGAL
1
2
9
END
END
D44D
LEGAL
1
2
9
END
END
D44E
LEGAL
1
2
9
END
END
D45
RANGE 0 97
LEGAL
58
99
END
END
D46A
LEGAL
1
2
9
END
END
D46B
LEGAL
1
2
9
END
END
D46C
LEGAL
1
2
9
END
END
D47A
LEGAL
1
2
9
END
END
D47B
LEGAL
1
2
9
END
END
D47C
LEGAL
1
2
9
END
END
D47D
LEGAL
1
2
9
END
END
59
D47E
LEGAL
1
2
9
END
END
D48
LEGAL
1
2
3
9
END
END
D49A
LEGAL
1
2
3
9
END
END
D49B
LEGAL
1
2
3
9
END
END
D50
LEGAL
1
2
3
9
END
END
D51A
RANGE 1 2
END
D51B
RANGE 1 2
END
D51C
RANGE 1 2
END
D51D
RANGE 1 2
END
60
D51E
RANGE 1 2
END
D51F
RANGE 1 2
END
D51G
RANGE 1 2
END
D52A
RANGE 1 3
END
D52B
LEGAL
1
2
9
END
END
D53
RANGE 1 2
END
D54
LEGAL
1
2
3
4
END
END
D55
RANGE 1 4
END
D56
RANGE 1 4
END
D57
RANGE 1 2
END
D58A
RANGE 1 2
END
D58B
LEGAL
1
2
3
9
END
61
END
D59
RANGE 1 2
END
D60
RANGE 1 2
END
D61
LEGAL
1
2
3
4
5
9
END
END
D62
LEGAL
1
2
3
4
9
END
END
D63
LEGAL
1
2
9
END
END
D64A
LEGAL
1
2
9
END
END
D64B
LEGAL
1
2
9
END
END
D64C
LEGAL
1
2
9
62
END
END
D64D
LEGAL
1
2
9
END
END
D66
LEGAL
1
2
3
9
END
END
D67A
RANGE 1 2
END
D67B
RANGE 1 2
END
D67C
RANGE 1 2
END
D67D
RANGE 1 2
END
D67E
RANGE 1 2
END
D67F
RANGE 1 2
END
D67G
RANGE 1 2
END
D68A
RANGE 1 2
END
D68B
LEGAL
1
2
8
END
END
63
D69A
LEGAL
1
2
9
END
END
D69C
LEGAL
1
2
8
9
END
END
D100A
RANGE 1 3
END
D100B
RANGE 1 3
END
D100C
RANGE 1 3
END
D100D
RANGE 1 3
END
D100E
RANGE 1 3
END
D100F
RANGE 1 3
END
D100G
RANGE 1 3
END
D100H
RANGE 1 3
END
64
Cleaning Programs
Community Informant Questionnaire (Form A) Cleaning Program
File Location and Name: E:\EPIINFO\CI_C.PRG
* Name of Program:
ci_c.prg
*Creating cleaning and new variable program for community informant data
type
type
type
type
type
type
type
type
type
type
type
" "
"This program will create a new clean dataset called ci_c.rec"
"from your community informant data and place it in the C:\EPI6\ drive."
"Use this program if you didnt use a check program when entering "
"data, or if you want to make sure that all the values in your "
"dataset are in range."
"If you want the cleaned dataset to be placed in another location,"
"you will need to edit this program using notepad, as indicated in"
"the Data Management and Analysis instruction document."
" "
"Enter the name and location of your community informant dataset below"
venu_c.prg
*Creating cleaning and new variable program for venue verification data
type
type
type
type
type
type
type
type
" "
"This program will create a new clean dataset called"
"venu_c.rec from your venue verification"
"data and place it in the C:\EPI6\ drive."
"Use this program if you didnt use a check program when entering "
"data, or if you want to make sure that all the values in your "
"dataset are in range."
"If you want the cleaned dataset to be placed in another location,"
65
type
type
type
type
"you will need to edit this program using notepad, as indicated in"
"the Data Management and Analysis instruction document."
" "
"Enter the name and location of your venue verification dataset below"
66
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
if
67
* Name of Program:
social_c.prg
*Creating cleaning and new variable program for socializing individuals data
type
type
type
type
type
type
type
type
type
type
type
" "
"This program will create a new clean dataset called social_c"
"from your socializing individuals data and place it in the C:\EPI6\ drive."
"Use this program if you did not use a check program when entering "
"data, or if you want to make sure that all the values in your "
"dataset are in range."
"If you want the cleaned dataset to be placed in another location,"
"you will need to edit this program using notepad, as indicated in"
"the Data Management and Analysis instruction document."
" "
"Enter the name of your socializing individuals dataset below"
68
69
if
if
if
if
if
if
D67F=1
D67G=1
D68A=1
D68B=1
D69A=1
D69C=1
or
or
or
or
or
or
=2
=2
=2
=2
=2
=2
70
ci.prg
" "
"This program will provide the information from the community informant"
"dataset that you will need for the PLACE Report template tables."
"This program will route its output into a text file"
"called ci_t.txt on the C:\EPI6\ drive."
"If you want the output to be placed in another location,"
"you will need to change the route command by editing this program"
"using notepad, as indicated in the Data Management and Analysis"
"instruction document."
" "
"Enter the name and location of your community informant dataset below."
"If you have a new, cleaned version of the dataset, make"
"sure to enter the name and location of the cleaned version of the dataset."
71
venu.prg
" "
"This program will provide the information from venue"
"verification that you will need for the PLACE Report template tables."
"This program will route its output into a text file"
"called venu_t.txt on the C:\EPI6\ drive."
"If you want the output to be placed in another location,"
"you will need to change the route command by editing this program"
"using notepad, as indicated in the Data Management and Analysis"
"instruction document."
" "
"Enter the name and location of your venue verification dataset below."
"If you have a new, cleaned version of the dataset, make"
"sure to enter the name and location of the cleaned version of the dataset."
72
73
freq
freq
freq
freq
C32A
C32B
C30A C30B C30C C30D C30E C30F C30G C30H C30I C30J C30K C30L
C31A C31B C31C C31D C31E C31F C31G C31H C31I C31J C31K C31L C31M
"Table 3.7.1
C35A C35B C35C C35D C35E C35F C35G C35H
C40
C42A C42B
type
freq
freq
freq
freq
freq
freq
"Table 3.7.2
C36
C37
C38
C39
C41
C42C
type
freq
freq
freq
"Table 3.8.1
C21
C30K C31K
C42D
type
type
type
type
type
type
"Table 4.2.1
"for types of venues and condom availability for 4.2.1,
"look up on Form C all venues where individuals socializing are interviewed
"using unique venue number (D4)
"For this table, you will need to limit the dataset to include only those
"venues where interviews with individuals socializing took place,
74
type "using the select command: "SELECT C2=A or C2=B or C2=C" etc.,
type "where A, B, C, etc. are the unique venue numbers of venues where type
"individuals socializing are interviewed. THEN run these commands:
freq C13
freq C42C
type "reset select
select
type "Table 5.1.1
type "For this table, you will need to limit the dataset to include only those
type "venues that have been selected as priority venues, using the select command:
type ""SELECT C2=A or C2=B or C2=C" etc., where A, B, C, etc.
type "are unique venue numbers of priority venues. THEN run these commands:
type "variable for venues where people meet new sexual partners:
freq meet_new
type "variable for venues where sex workers solicit:
freq sex_sol
type "variable for venues where IDUs socialize:
freq idu_soc
type "variable for venues where students/youth socialize:
freq sy_soc
type "variable for venues where mobile populations socialize:
freq mob_soc
type "variable for venues where men who have sex with men socialize:
type "New variables for criteria formation; 1=criteria met, 0=criteria not met
if total>=3 then crit_1=1 else crit_1=0
freq crit_1
if C4>=15 then crit_2=1 else crit_2=0
freq crit_2
if C28B>25 then crit_3=1 else crit_3=0
freq crit_3
type "criteria 4: locally relevant venues chosen, not part of database
type "Priority level: number of criteria 1-3 met (not including criteria 4)
level=crit_1+crit_2+crit_3
define lev_num _______
recode level to lev_num 0=level_4 1=level_3 2=level_2 3=level_1
type "reset select
select
route screen
social.prg
75
type
type
type
type
type
"instruction document."
" "
"Enter the name and location of your socializing individuals dataset below."
"If you have a new, cleaned version of the dataset, make"
"sure to enter the name and location of the cleaned version of the dataset."
76
77
78
79
80
81
82
set statistics=on
set ignore=on
type "next, need to select men and women separately, but still select only
interviews
type "that took place with willing and eligible persons:
type "mean for MEN:
select
select D14=1 and D11=1
freq D35
type "mean for WOMEN:
select
select D14=1 and D11=2
freq D35
type "RETURN selection to all eligible and willing to to be interviewed:
select
select D14=1
type "RETURN statistics to off and Don't ignore missing values:
set statistics=off
set ignore=off
type "categories for total new partner number past 12 months
define pnlasty ______
recode D36 to pnlasty 0=0 1=1 2=2 3-9=3_9 10-99=10+ .=missing
tables pnlasty D11
type "for mean number, turn statistics on and ignore missing values:
set statistics=on
set ignore=on
type "next, need to select men and women separately, but still select only
interviews
type "that took place with willing and eligible persons:
type "mean for MEN:
select
select D14=1 and D11=1
freq D36
type "mean for WOMEN:
select
select D14=1 and D11=2
freq D36
type "RETURN selection to all eligible and willing to to be interviewed:
select
select D14=1
type "RETURN statistics to off and Don't ignore missing values:
set statistics=off
set ignore=off
type "***Table 4.8.2
type "select those with two or more partners in past 12 months (and interviewed)
select
select D35>1 and D14=1
type "age categories for 4.8/2
define ageg2 _____
recode D12 to ageg2 15-19=15_19 20-24=20_24 25-29=25_29 30-39=30_39 40-99=40+
.=missing
tables ageg2 D11
type "return to all interviewed
select
select D14=1
type "***Table 4.9.1
tables rate D11
83
84
85
all >0
all >0
condom
all >1
percent used condom at
86
87