I am trying to use one-step system GMM in stata using xtabond2 but keep getting the error 'no observations' r(2000). I think this might be because I have some missing data in my panel but it is an unbalanced panel so shouldn't matter. my code so far is, thank you in advance for having a look.
clear all
set more off
capture log close
ssc install xtabond2
cd "C:\Users\bethc\OneDrive\Documents\Dissertation\da ta\dissertation"
insheet using "DATA.csv",names
generate lngdp = ln(gdp)
generate ginip = 100*gini
encode country, gen(country1)
generate growthp = growth*100
clear matrix
xtset country1 year
xtabond2 growth l.lngdp l.ginip l.fert l.femaleeduc l.maleeduc cpi i.year, gmm(lngdp, laglimits(2 3) eq(diff)) gmm(d.femaleeduc d.maleeduc d.ginip d.fert cpi, laglimits(1 1) eq(diff)) gmm(femaleeduc maleeduc fert, laglimits(1 1) eq(level)) gmm(cpi, laglimits(0 0) eq(level)) iv(i.year) h(2) noconstant robust
Related Posts with no observations when using GMM xtabond2
Reassigning records with missing values to existing categories considering the existing distribution within the populationDear Statalist, I am struggling to reassign records with a missing value on the categorical variabl…
Removing duplicates across several variables in panel data and keep the dup with non-missing valuesHi As the title suggests, I am trying to remove duplicate values across several variables (c30) in …
xtreghello, I have a dataset on which I want to perform an OLS. The dataset looks like this: dependent v…
Problem with saving graphs with wildcard in namesHi there! I'm having some difficulties saving and combining graphs that I have created using a fore…
Seemingly Unrelated Regression with endogeneity and sample selectionHello everyone! I wish to see the impact of income from an activity on various types of household ex…
Subscribe to:
Post Comments (Atom)
0 Response to no observations when using GMM xtabond2
Post a Comment