Quantcast
Channel: Statalist
Browsing all 73247 articles
Browse latest View live
↧

Restoring first stage estimates with ivreghdfe (ivreg2 based command) and...

Hi, I am running a regression with ivreghdfe (which builds on ivreg2) and I want to restore the first stage estimates. I have done so previously. Usually, I would do something like this for a single...

View Article


eclplot command

Hello dear, Please I learn how to use eclplot command. From Stata help, I run the example: . sysuse auto,clear . parmby "xi:regress mpg i.foreign i.rep78", label norestore . sencode parm,gene(parmid)...

View Article


Some GPS coordinates not responsive

Hello Stata community I have GPS coordinates, where some coordinates have latitude and longitude values of 0.000000. I want to replace these values as missing, so I use the command replace lat = . if...

View Article

Stata code to estimate stock price effects of regulation

Hi Stata Community, I am trying to estimate the stock price effects of a regulation that affects a certain set of firms in a specific industry. This regulation involved 3 event dates in which different...

View Article

Issue with missing values in matrix with csdid

Hello-- I have been working on implementing Calloway and Sant'Anna's staggered DID specification using Code: csdid . I have developed a collapsed state-level balanced panel pre-estimation. I run the...

View Article


Export results from misstable sum to excel

Hi! I need to save the results from misstable sum in excel. Should not be too hard, but so far, I got only an empty excel sheet or error messages. Thanks in advance for helpful code.

View Article

Strange Watermark in Plot

One of my students submitted a plot in a paper with this strange watermark at the bottom right. Doesn't seem to be something StataCorp would tolerate in their default graphics.... and quite the odd...

View Article

Text in different plotregions of coefplot

Dear all, In the code I attach below I would like this text: text(-9 1 "N= $empL_N_1" -9 2 "N= $empL_N_2" -9 3 "N= $empL_N_3" , size(small)), to appear only in first plotregion, and this text text(-10...

View Article


Combining two value labels into one

Dear Statalist, I am looking for a way to merge two variable labels into one. I have two variables, var1 and var2, with corresponding value labels (lab1 and lab2). - var1 ranges from 1 to 100, and lab1...

View Article


Looping over Mata Program/Solvenl

Hello. I'm trying to perform 2 tasks: the first is to loop over a numerical solution for a parameter, and the second is to take the results of the solution and save them into STATA for use as a graph....

View Article

Discrete choice experiments: Stata's dcreate command for a continuous variable

Hello? I am designing a discrete choice experiment using Stata's dcreate command. I have encountered an unexpected situation while creating a partial factorial design, and I wonder if anyone knows...

View Article

offest in gee models and collinearity issues

Hi everyone, I am working on a paper looking at the mental health hospitalisations of mother of children placed in foster care 2 years before and 2 after placement, aiming to assess if mothers are more...

View Article

Discrete choice experiment: trade off between choice sets and data points

Hello DCE experts? I am designing a discrete choice experiment using Stata's dcreate command. I have a general question concerning the trade off between obtaining more data points from a smaller number...

View Article


Macro loop to create labels for graph

Hi I have a graph and I want to add text labels at various points I am trying to do this with a loop as the number of labels is large I was trying to create a "text" string to append to the end of my...

View Article

Simplest way to permanently change result level labels of...

I would prefer to replace these with something shorter like "N" and "%" permanently. Currently I am working harder and stupider by running a collect label levels command after the table command. Thanks

View Article


Using Propensity Score Matching to Select a Sample

I have a list of several hundred schools with 65 of them being treatment schools. I want to use propensity score matching to choose the 35 treatment and 35 control schools that are most alike based on...

View Article

Looping over files to create new datasets

Hi. I have four files in a folder that have the following naming convention: "emr22-24_`x'.dta". I want to run a loop over them that does the following: 1. generates a new binary variable (median_tele...

View Article


Stata (Struggling to Obtain Covariance Matrix from Multi-Company Data)

Hello, I have been trying to obtain a covariance matrix for quite some time. The problem gets a bit more complicated, as I have the data arranged in such a way that I have 174 rows (every 29 rows...

View Article

increase dpi in figure files

Dear Stata friends, how to increase dpi in figure files? The journal requires 300-600dpi JPEG/Tif figure files. I can only produce 96dpi files from -graph export-. My procedure was like this: sysuse...

View Article

xtreg versus reghdfe

Hai. I wanna ask something about my work. I do hausman test <xtreg depvar indvar, fe vs xtreg depvar indvar, re>, and the selected model is fixed effect model. I wanna add year fixed effect,...

View Article
Browsing all 73247 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>