Skip to content

Instantly share code, notes, and snippets.

View umran's full-sized avatar
🌊
stoked!

Umran Hussain umran

🌊
stoked!
  • Irukandji Labs
  • Vancouver, BC
View GitHub Profile
gen sex_of_first_born = .
foreach i in b4_16 b4_15 b4_14 b4_13 b4_12 b4_11 b4_10 b4_09 b4_08 b4_07 b4_06 b4_05 b4_04 b4_03 b4_02 b4_01 {
if(`i' ==.) {
continue
}
replace sex_of_first_born = `i'
}
gen sex_of_first_born = .
foreach i in b4_16 b4_15 b4_14 b4_13 b4_12 b4_11 b4_10 b4_09 b4_08 b4_07 b4_06 b4_05 b4_04 b4_03 b4_02 b4_01 {
if(`i' ==.) {
continue
}
replace sex_of_first_born = `i'
}
clear all
cd "~/irukandjilabs/econ490"
use "data/Women_complete_3states.dta"
gen children_ever_born = v201
gen done = 0
replace done = 1 if v605 == 5 | v605 == 6 | v605 == 7
recode done 0 = . if v605 == .
gen tfr = children_ever_born if done == 1
clear all
cd "~/irukandjilabs/econ490"
use "data/Women_complete_3states.dta"
gen children_ever_born = v201
gen done = 0
replace done = 1 if v605 == 5 | v605 == 6 | v605 == 7
recode done 0 = . if v605 == .
gen tfr = children_ever_born if done == 1
clear all
cd "~/irukandjilabs/econ490"
use "data/Women_complete_3states.dta"
gen children_ever_born = v201
gen done = 0
replace done = 1 if v605 == 5 | v605 == 6 | v605 == 7
recode done 0 = . if v605 == .
gen tfr = children_ever_born if done == 1
clear all
cd "~/irukandjilabs/econ490"
use "data/Women_complete_3states.dta"
gen children_ever_born = v201
gen done = 0
replace done = 1 if v605 == 5 | v605 == 6 | v605 == 7
recode done 0 = . if v605 == .
gen tfr = children_ever_born if done == 1
clear all
cd "~/irukandjilabs/econ490"
use "data/Women_complete_3states.dta"
gen children_ever_born = v201
gen done = 0
replace done = 1 if v605 == 5 | v605 == 6 | v605 == 7
recode done 0 = . if v605 == .
gen tfr = children_ever_born if done == 1

Keybase proof

I hereby claim:

  • I am umran on github.
  • I am umranh (https://keybase.io/umranh) on keybase.
  • I have a public key ASBfOrsKzxVQFjJEL_aoQNvxYlx5H370yXYokO0nWHhsWwo

To claim this, I am signing this object:

const util = require('util')
const flatten = (obj, progress, path=null) => {
Object.keys(obj).forEach(key => {
let parentPath = path ? path.concat('.', key) : key
if (isPrimary(obj[key])) {
progress[parentPath] = obj[key]
} else {
flatten(obj[key], progress, parentPath)
fn main() {
// create a new String
let mut original_string = String::from("Toulouse");
{
// create a mutable (mut) variable that mutably (&mut) borrows the original String
let mut first_reference = &mut original_string;
// create another variable that mutably (&mut) borrows the previously created reference
let second_reference = &mut first_reference;