Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Introduction to Labels - Econometrics - Lecture Slides, Slides of Econometrics and Mathematical Economics

Introduction to Labels, Working with Data Labels, Variable Labels, Value Labels, Developing skills to ADD, Use of Labels in Stata, Types of labels, Adding Label to a Data Set are key and learning points in this lecture of Econometric.

Typology: Slides

2011/2012

Uploaded on 11/10/2012

uzman
uzman 🇮🇳

4.8

(12)

148 documents

1 / 51

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
INTRODUCTION TO LABELS
Working with Data Labels, Variable Labels and
Value Labels
I
Docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33

Partial preview of the text

Download Introduction to Labels - Econometrics - Lecture Slides and more Slides Econometrics and Mathematical Economics in PDF only on Docsity!

1

INTRODUCTION TO LABELSWorking with Data Labels, Variable Labels and

Value Labels

I

2

Objectives

-^

The Objectives of this lecture are:

-^

Developing skills to ADD:– Data Label– Variable Labels– Value Labels– Looking at Value Label in Detail

4

1. Adding Label to a Data Set

-^

First

load

a^

data

set

named

“personal

data

with

labels.dta”.

-^

Type ‘describe’ to see the data set and its variables.

•Note that no label is attached with the data.

Docsity.com

5

1. Adding Label to a Data Set

Now to add label to the data, do the following steps:Go to Data Menu

Æ

Select Labels

Æ

Select label data set

form the submenu.

7

1. Adding Label to a Data Set

To see the attached label to the data set. Type describe in

command window.

NOTE: Now the label appears

8

2. Adding Labels to Variables

Type ‘describe’ to describe the data.

Note that there are no labels attached withthe variables in your data.

10

2. Adding Labels to Variables

A dialogue box appears.

Select

“Attach

a^

label

to

a^

variable”

and

in

the

variable dropdown menu Sele

ct the variable to which

you want to add a label say “id” and add a new labelas “identifier” and Click submit.

11

2. Adding Labels to Variables

You can label all variables in the same manner.I labeled ‘id’ by “identifier”, ‘age’ by “age of a person”, ‘sex’

by “sex of a person” and ‘edu’ by “education of a person”. Now look at the variable window.

13

3. Adding Value Labels

Two

steps

are

required

to

assign^

the

labels

to

values

of

variables. Step 1:

Define a value label.

Step 2:

Assign the Defined value label to a particular variable.

Type ‘describe’ to describethe data. Note that

no

value

labels

are attached.

Docsity.com

14

3. Adding Value Labels

Open data file named ‘personalinfo.dta’. Click Browse data to

see the data.

Note that

the

variable

‘sex’

has values 1 and 2.The 1 represents ‘male’ and 2represents ‘female’.

16

3. Adding Value Labels

A dialogue box appears named “Define value labels”.

17

3. Adding Value Labels

Click

“Define”

and

give

a^

label

name ‘mf’ for male and female. Click Ok.Now a new dialogue box appears.In the value write ‘1’ and in the text

option write ‘male’. Click Ok.

19

3. Adding Value Labels

The resulting window should look like the one shown

below:

When all the labels are assigned,

Click Close.

20

3. Adding Value Labels

Step 2: Assign value labels to variable Go to Data Menu

Æ

Select value labels

Æ

Select assign value

labels to variables.