-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmp_dta.mpb
40 lines (31 loc) · 830 Bytes
/
mp_dta.mpb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<header>
<mkproject> boilerplate
<version> 2.1.0
<label> data preparation
<description>
{pstd}
This is a template for a .do file that cleans the data.
</description>
</header>
<body> -------------------------------------------------------------------------
capture log close
log using <stub>.txt, replace text
// What this .do file does
// Who wrote it
version <stata_version>
clear all
macro drop _all
*use ../../posted/data/[original_data_file.dta]
*rename *, lower
*keep
// prepare data
*gen some_var = ...
*note some_var: based on [original vars] \ <fn> \ [author] TS
*compress
*note: <abbrev>##.dta \ [description] \ <fn> \ [author] TS
*label data [description]
*datasignature set, reset
*save <abbrev>##.dta, replace
log close
exit
</body> ------------------------------------------------------------------------