Using Custom Scalars in esttab main() and aux()
I am running a logit model, and doing a non-linear test afterwards. I want to display the test statistic and p-value from the test, not the coefficients from the logit. Here is a MWE:
Using mata function inside `nlcom`?
I’m interested in a function that does not admit a closed-form expression, so I approximate it using a mata function.
Stata putexcel: add numbers with stars to a table
I want to create a table for excel, based on numbers from Stata. A cell might have a number and stars (indicating statistical significance), such as “0.15***”.
two different encoding in STATA Dataset
I need to import data from a Microsoft SQL Server View into STATA. I do that using odbc. That works also great. Unfortunately, I have two variables with an encoding Problem. Both Variables contain strings that have Umlaute in the german language (ä, ö, ü, ß). The weird thing is, that there are other variables containing Umlaute which are shown correctly. I used filefilter to change the encoding to utf-8, which corrected the two variables. But now all the others are not shown correctly anymore. Unicode analyze gave me the following output:
Stata regression table
I need help creating a regression table in Stata for LaTeX. I want to include different regression specifications (in columns) and different outcome variables (in rows) in the same regression table. Here is what I have so far:
Adding Control:
frmttable won’t replace my tables despite using replace – I have to manually delete them
I am having an issue with the frmttable command in Stata. I add the replace in it and it always gives me the error that the file already exists. I then have to manually delete the file. A sample of the code I use is below:
did_multiplegt_dyn with controlvariables
I run a staggered DiD regression with the Stata command did_multiplegt_dyn by De Chaisemartin, C., & d’Haultfoeuille, X. (2024). Without control vars the command runs
How can I create a day number variable in Stata based on dates?
I want to create a variable with the number of the day a participant took a survey (first day, second day, thirds day, etc.) The issue is that there are participants that took the survey after midnight. For example, this is what it looks like:
Lagged range in if statement
I have successfully used lagged values in the “IF” section of a replace. How do I specify a range instead of each individual lagged variables. Iteration is not an option. I have ~10million observations.
ivmediate – mediator explains always the same % of the total effect
I am using Stata 14, and the command ivmediate.