Tagged Questions

Stata is a proprietary cross-platform general-purpose statistical software package.

learn more… | top users | synonyms

2
votes
0answers
16 views

Aggregating forcast to higher spatial level

I am working on a project doing out of sample estimates of wheat yields at the village level in STATA. I am using a short panel 3 years and a sample of ~3000 villages. We are estimating a RE model and ...
1
vote
1answer
49 views

Customizing a graph with gray regions

I'd like to do a graph similar to this one with the gray regions to point the recessions in my graph. I have R and Excel and Stata, I'm simply trying to make it easy to distinguish the recessions by ...
0
votes
1answer
40 views

How do I interpret a variance ratio test in Stata?

I need help with interpreting output from a Variance Ratio Test in Stata. $f = 1.2988$ (my variance) $\text{Degrees of freedom} = 249, 493$ I have Ho: ratio = 1 as my null Ha: ratio != 1 Am I ...
0
votes
0answers
41 views

What is the difference between FE-PCSE and xtreg, fe in Stata?

Here is a very simple question: On country-level data, I am running two different fixed effect model, using Stata command, but I don't know why not only the estimation of standard errors, but also ...
0
votes
1answer
26 views

Wage Equations: Extracting from a schooling dummy years of schooling

I'm running wage equations and have in my data only highest level of education attained which takes the values of 1, 2 and 3. I am trying to calculate the mean years of schooling and standard ...
1
vote
0answers
20 views

Alternative specific conditional logitstic regression with clustering on in individual in panel data: scientifically and computationally reasonable?

My scientific interest is to calculate the price elasticity for an overall set of products (books) in a panel dataset of observations over a 3 year period and I was wondering whether asclogit ...
1
vote
1answer
72 views

Hausman test after xtregar negative chi2

I'm performing a Hausman test on panel data to determine whether to choose Random Effects or Fixed Effects for my analysis with AR(1). After performing the test I get a negative $\chi^2$ statistic ...
0
votes
0answers
26 views

White noise test interpretation

How to interpret white noise test from Stata? Have a white noise means that a variable does not have autocorrelation. Can I say here that all of my variables has a white noise (does not have ...
3
votes
0answers
17 views

Post-hoc power analysis of complex sample survey data

I am working with a complex sample survey data using Stata to determine the predictors of a given dependent variable. As part of my analysis result I want to report the post-hoc power for each ...
-1
votes
0answers
12 views

Stata Deleting Multiple Observations [migrated]

I have the following data matrix containing ideology scores in a customized dataset: ...
0
votes
0answers
19 views

Convert variable value from two variables into a separate variable value [migrated]

I have the following data matrix containing Poole dw-nominate scores: ...
0
votes
0answers
11 views

PACF and ACF for AR and MA detection

I am very new to SARIMA and I am really facing a poblem which p,q,P,Q to use. Here is ACF and PACF of first-difference, two first plots (stationary) and ACF and PACF of first-seasonal difference (two ...
2
votes
1answer
32 views

SARIMA, coefficients check

I would appreciate if someone could check the mathematical equation for the seasonal ARIMA (4,1,4) x (1,1,1) period 12 that I wrote. I have done it this way, but I am not really sure if it correct is. ...
0
votes
0answers
11 views

Stata keeping even years [migrated]

Simple question everyone, if I have data for every year of 1932 to 2012, how do I keep only the even number years from 1946 to 2012 in Stata? I've tried the following: ...
0
votes
1answer
43 views

How can I estimate Tobit type 4 or 5 in Stata?

How can I estimate Tobit type 4 or 5 in Stata? I need to estimate Tobit type 4 model in Stata but I can't find any papers about it.
0
votes
0answers
6 views

Nearest Neighbor Matching in Stata [migrated]

I need to program a nearest neighbor algorithm in stata from scratch because my dataset does not allow me to use any of the available solutions (as far as I am concerned). To be pecise. I have a ...
1
vote
1answer
69 views

How to implement ordinal logistic regression for a factorial design

I have read a few answers (e.g. this, this and this) recommending to use the Ordinal Logistic Regression (OLR) as a generalized method when the Kruskal-Wallis is not suitable. For instance, a 2x2 ...
0
votes
0answers
6 views

esttab and nobaselevels - dropping coefficients with 0 estimated [migrated]

I'm trying to drop the 0 coefficients for a model using the option, nobaselevel in stata: working example here: ...
0
votes
0answers
63 views

Multilevel analysis in R and Stata

I am trying to replicate a multilevel logistic analysis which uses a dyadic time series data set and R. As for my part, I am using the same data set but Stata. The original syntax has the following ...
0
votes
0answers
18 views

zinb estimates change when using factor variables

I use Stata SE 13 and I have a problem with the command zinb in Stata. I have binary variable female which is 1 if respondent is female, 0 otherwise (no other ...
0
votes
1answer
32 views

Interaction Dummy

I have a model: $$ \ln({\rm earnings}) = 2.618656-0.0899657{\rm female}+0.382019{\rm white}-0.2754126{\rm female}\times{\rm white} $$ ${\rm female}$ and ${\rm white}$ are dummy variables. t= ...
0
votes
0answers
29 views

Dummy variable interpretation [duplicate]

I have a model: $$ \ln({\rm earnings}) = a+b_1{\rm female}+b_2{\rm white}+b_3{\rm female}\times{\rm white} $$ ${\rm female}$ and ${\rm white}$ are dummy variables. t= female=-1.65 white=8.86 ...
0
votes
0answers
8 views

Problem displaying st. errors after lincom using outreg2 [migrated]

I am running two regressions in Stata: one without controls and another with controls. I'm using lincom to find the coefficient and se for the sum of two of my regressors. I am then using outreg2 to ...
0
votes
0answers
29 views

Obtain factor scores in data set with missing values

I would like to obtain factor scores after factor analyzing data that contain missing values. I'm using Stata 13 to run the analysis. Here is the basic code (borrowed from the UCLA site): ...
1
vote
2answers
29 views

Using variance from a Jeffreys prior in a Prevalence meta-analysis

I am doing a meta-analysis on a group of studies, where the observation is a rate (no. of successes / no of trials). Some of the studies have small sample sizes (n<10) and/or did not observe any ...
1
vote
1answer
41 views

Which p-value to report in a comparison of different logistic regression models using marginal effects?

I am running logistic regression models to compare the impact of different indicators using Stata. As these comparisons may lead to false conclusion due to confounding and rescaling if log-odds or ...
1
vote
1answer
92 views

Fuzzy RDD issue

I am fairly new to econometrics and maybe this is a very basic question to some. I am running a Fuzzy Regression Discontinuity (RD) design in Stata and I am having doubts about whether I am ...
0
votes
0answers
22 views

within-MZ twin model using sem in Stata

I'm working with some twin data and would like to estimate something exactly akin to xtreg using sem in Stata. The structure of the data is pretty generic: there's a family id, there's a within family ...
1
vote
0answers
35 views

attenuation percentage and confidence interval

I made a logistic regression model 1 (not fully adjusted) and model 2 (fully adjusted; model 1 + covariate A) with Stata. I am trying to calculate the attenuation percentages between OR. I used the ...
2
votes
1answer
121 views

Why does a confidence interval including 0 mean the difference is not significant?

Could someone please explain why zero being inside or outside the confidence interval tells you whether or not the difference is significant?
0
votes
1answer
23 views

pairwise comparison with Dunnett's adjustment in Stata

I am comparing the means of days between notification and diagnosis for 13 years, as I want to know if the mean days from 2013 is significantly different from the previous 12 years. I was thinking ...
0
votes
1answer
42 views

How to attach parents' educational attainment to their children in Stata? (Using IPUMS - USA dataset) [closed]

I am interested in the relationship between children's success in high school and their mother's educational attainment. For this reason, I would like to create a variable called mom_education, which ...
2
votes
1answer
74 views

Levinsohn-Petrin TFP estimation in Stata without proxy

I'm trying to compute TFP by using levpet Stata command. I use revenue estimation, yet it requires proxy option which is intermediate input (usually material ...
0
votes
0answers
27 views

Run Tobit with missing values (from linear prediction) or change them to zeros - STATA “practical” question

I want to run a Tobit linear regression in order to especify a labor-supply curve (linear-linear). As dependent variables I have personal characteristics, enviromental ones, and wages (predicted using ...
0
votes
1answer
46 views

How to visualize cluster data in a scatter way

Having a clustered dataset, I want to visualize a scatter plot for two fields so every cluster is shown on the plane by its mean value (also good to have a radius equal to std). How does one do this ...
2
votes
3answers
130 views

How do I detrend time series?

How do I detrend time series? Is it ok to just take first difference and run a Dickey Fuller test, and if it is stationary we are good? I also found online that I can detrend the time series by ...
0
votes
1answer
35 views

Oaxaca Decomposition: Unexplained Constant

I am doing an Oaxaca decomposition of the Log Wage Differential between Whites and non-Whites. I would like to find out if there is any interpretation for the constant term under the unexplained ...
1
vote
2answers
72 views

How can I compare two regression models?

I have two OLS regression models (in Stata): (1) Y = a + b_1 X_1 + b_2 X_2 + fixed effects + e (2) Y = a + b_1 X_1 + b_2 X_2 + b_3 (X_1 * X_2) + fixed effects + e ...
1
vote
1answer
104 views

Two sample Kolmogorov-Smirnov test for the stochastic dominance

I'm trying to use KS test to determine whether one group of data is scholastically dominates another. So I'm studying dataset regarding performance of companies, which are divided into 2 groups. ...
0
votes
0answers
44 views

Propensity score matching by gender in stata

Hello Stack Community! I'm trying to do a matching in Stata. I need to do a propensity score matching between a single individuals dataset (men and women) to a couple dataset. What I like to do is to ...
0
votes
0answers
32 views

Two-stage probit least squares

I am estimating a two-stage probit least squares (2SPLS) model. From the readings I have done so far, it appears the first stage of the 2SPLS has to be estimated with a probit, and then a continuous ...
0
votes
0answers
24 views

Multivariate regression with 3 dependent variables and only 1 independent variable?

I need to compare the marginal effect of one independent variable (X) in 3 different dependent variables (Y). I did a multivariate regression using Stata commands manova and mvreg, but I am doubting ...
6
votes
2answers
134 views

Propensity Score Matching with time-varying treatment

The basic propensity score matching procedure works with cross-section data (ie collected at a certain point in time). The popular psmatch2 command uses a dummy variable indicating that an ...
2
votes
2answers
103 views

Replicating Stata's “robust” option in R

I have been trying to replicate the results of the Stata option robust in R. I have used the rlm command form the MASS package ...
1
vote
1answer
48 views

Cross-sectional Regression (individual level) with a few country-level variables

I have a small sample of 50 cross-sectional firms and 3 or 4 distinct explanatory variables -- all on the individual level. No time dimension. So far, I could employ OLS (I am using Stata: ...
1
vote
0answers
38 views

Compare $R^2$ statistical significance in multivariate multiple regression

I have a multivariate multiple regression model with 3 dependent variables and the same 5 covariates. I used manova and mvreg in ...
1
vote
2answers
160 views

What probability distribution best describes my data?

I have a variable whose values are summated scale scores constrained within the range 3 to 21, inclusive. I considered this variable as a scale variable (though with restricted range). In order to ...
2
votes
0answers
63 views

Replicating stata results in R

I'm working with a faculty member who wanted me to do the data work in Stata, but now wants me to estimate the models in R as well because the graphics are more flexible. However, I'm having some ...
0
votes
0answers
21 views

Which panel to pick when there is overdispersion in longitudinal data?

This question relates to a previous question I asked a while ago that unfortunately remained unanswered. I hope someone can give me an answer or a suggestion / comment that could help me out. I am ...
0
votes
0answers
66 views

Empirical Bayes estimates of fixed effects (STATA 12)

I want to calculate the empirical Bayes estimates of the fixed estimates estimated using xtmixed in STATA. I conceptually understand what it is trying to do, but I'm not sure how to implement it in ...