From the course: Introduction to Stata
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Saving data - Stata Tutorial
From the course: Introduction to Stata
Saving data
- [Franz] In this session we're going to explore how we can save our data once we're happy with it. However, before we dive into Stata it is very important to recognize that saving data can be much more dangerous than loading data. Stata will overwrite your previous data if you specify the relevant option, and generally you will. It will not ask you "are you sure?" There is no back button in Stata, once your previous data is replaced or overwritten, that's it. Your original data source is gone. Therefore, always work with a copy. I cannot emphasize this enough, and this should always be part of your good data practice. The two commands that matter for saving data in Stata are CD, which is short for current directory, and save, which will save your data. So let's head over to Stata and explore these two. Here we are in the auto data. Imagine that we've just finished some sort of data manipulation exercise, and…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Recoding an existing variable4m 3s
-
(Locked)
Generating a new variable5m 15s
-
(Locked)
Naming and labeling variables5m 20s
-
(Locked)
Extended generate3m 26s
-
(Locked)
Indicator variables4m 7s
-
(Locked)
Keeping and dropping variables3m 9s
-
(Locked)
Saving data3m 6s
-
(Locked)
Merging and appending6m 54s
-
(Locked)
String variables5m 53s
-
(Locked)
Local macros and looping7m 12s
-
(Locked)
Manipulating data: Challenge45s
-
(Locked)
Manipulating data: Solution4m 7s
-
(Locked)
-
-
-
-
-
-
-