Sie sind auf Seite 1von 13

Statistika

Referensi : Installer SPSS v 16.0

Reading Data
Data can be entered directly, or it can be imported from a number of different sources. The processes for reading data stored in SPSS-format data files; spreadsheet applications, such as Microsoft Excel; database applications, such as Microsoft Access; and text files are all discussed in this chapter.

Basic Structure of an SPSS-format Data File


SPSS-format data files are organized by cases (rows) and variables (columns).

Reading an SPSS-format Data File


SPSS-format data files, which

have a .sav file extension, contain your saved data. From the menus choose: File Open Data...

Reading Data from Spreadsheets


Rather than typing all of your

data directly into the Data Editor, you can read data from applications such as Microsoft Excel. From the menus choose: File Open Data... Select Excel (*.xls) as the file type you want to view.

Reading Data from Spreadsheets


Make sure that Read variable

names from the first row of data is selected. This option reads column headings as variable names. Since variable names can't contain spaces, the spaces from the original column headings have been removed. For example, Marital status in the Excel file becomes the variable Maritalstatus. The original column heading is retained as a variable label.
6

Entering Numeric Data


In the first row of the first column,

type age. In the second row, type marital. In the third row, type income. Or you can copy-paste from anywhere Click the Data View tab to continue entering the data.

Entering String Data

Select String to specify the variable Click the Variable View tab at the

bottom of the Data Editor window. Click the Type cell next to your entry. Click the button on the right side of the Type cell to open the Variable Type dialog box.

type Click OK to save your selection and return to the Data Editor.

Entering String Data

Select String to specify the variable Click the Variable View tab at the

bottom of the Data Editor window. Click the Type cell next to your entry. Click the button on the right side of the Type cell to open the Variable Type dialog box.

type Click OK to save your selection and return to the Data Editor.

Adding Value Labels for Numeric Variables

Value labels provide a method for

mapping your variable values to a string label. In this example, there are two acceptable values for the marital variable. E.g A value of 0 means that the subject is single, and a value of 1 means that he or she is married.

Click the Values cell for the marital

row, and then click the button on the right side of the cell to open the Value Labels dialog The value is the actual numeric value. The value label is the string label that is applied to the specified numeric value.
10

Adding Value Labels for Numeric Variables


Type 0 in the Value field. Type Single in the Label field.

Click Add to add this label to the

list. Type 1 in the Value field, and type Married in the Label field. Click Add, and then click OK to save your changes and return to the Data Editor.

11

Adding Value Labels for String Variables


Click the Values cell row, and then

click the button on the right side of the cell to open the Value Labels dialog box. Type F in the Value field, and then type Female in the Label field. Click Add to add this label to your data file. Type M in the Value field, and type Male in the Label field. Click Add, and then click OK to save your changes and return to the Data Editor.

12

Adding Value Labels for String Variables

13

Das könnte Ihnen auch gefallen