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

clustering and concentration Stata code

Hi everyone, I am in the process of writing one of my dissertation chapters. Using US Census and ACS, I want to measure Middle Eastern and North African immigrants’ spatial concentration and...

View Article


extract year

Dear All, How can I extract year (Stata format) from the following variable? Code: * Example generated by -dataex-. To install: ssc install dataex clear input str9 date "28-Jun-95" "29-Jun-99"...

View Article


Counting the number of ID type for each country in the data

Hi, My Panel data has 260 Panel IDs(firms) over a number of time period and another variable names as ID_Type (which is either 1 or 2 for each ID(firm)) and a third variable stating total 12 countries...

View Article

How to rescale A variable by range

Hello statalist members, i want to rescale my contious variables(x,y) by range(maximum-minimum) because of my other variables which are dichotomous.so i want to rescale my contious variables(x,y) so...

View Article

How check if value in one variable is equal to any value in other variables

I am trying to gen a variable or variables that say VAR1 has elements in commons with other 2 variables (VAR2 and VAR3), VAR2 has element in common with only one variable (VAR4), VAR 3 has elements in...

View Article


Textbox position in bar graphs

I am trying to change the position of subtitles in bar graphs. I've created a MWE from Stata's dataset: Code: use http://www.stata-press.com/data/r15/lifeexp, clear graph bar, over(lexp) by(region) I...

View Article

Image may be NSFW.
Clik here to view.

How drop some elements from a macro list of files

Hi Statalist I have a question. I have the following datasets: 2008_a8.txt, 2010_a4.txt, 2012_a7.txt, 2014_a5.txt, 2015_a2.txt and 2016_a3.txt. A first part of my .do file generate the following...

View Article

Help with counts

Hello, I am working on a prescribing data set containing details of about 100,000 people. The lay out is similar to the table below: ID Gender (0=male, 1=female) Paracetamol_2002 (0=no, 1=yes)...

View Article


coefplot graph, symmetry between dots

Dear Statalisters, I am using the coefplot command to create one graph with coefficients from 40 different regressions However, the position of the dots in the chart is not symmetric, as you can see...

View Article


bayesgraphs diagnostics in Item Response Model

Please, how do we use bayesgraphs diagnostics command in Item Response Model? Thanks for your anticipated assistance. olayiwola Adetutu Kwara state University Malete, Nigeria.

View Article

How to look at regression between score bands

Hi, I have a binary variable and a score variable. I want to look at the binary variable in different bands of the score variable (specifically, 0-10, 10-20, 20-30 >30). Not sure how to do the...

View Article

Interpreting Xtabond2 Coefficients & Coefficient Inflation?

Hi, This is a follow-up question for this topic, but because the question is different, I thought may be it can be more useful in the future if someone searches this question. Older topic:...

View Article

How to generate predicted wage (gap) with margins command and plot a profile...

Dear Stata user, I would like to have predicted mean immigrant-native wage gaps on the vertical axis and years since migration (ysm) on the horizontal axis and generate such a profile based on the...

View Article


coefplot chang bar color?

My question is how can I change the bar colors when I`m using HTML Code: coefplot I added this HTML Code: bar(1,bcolor(navy)) bar(2, bcolor(maroon)) but it says: option bar() not allowed r(198); HTML...

View Article

Getting an error from putexcel set ..., open

I have this simple line of code to setup my excel worksheet but I get the following error when I try to run it: putexcel_set_new(): 3010 attempt to dereference NULL pointer <istmt>: - function...

View Article


Coefplot: reduce spacing on y-axis

Hello everybody, I have a question about how to reduce the spacing between labels on the y-axis when using Benn Jann's coefplot command. This is related to a post I found on stackoverflow,, but the...

View Article

test

test ist by Code: desc http://das

View Article


bootstrap doesn't work for handling endogenity for mlogit

Hi Dear Statalist, I want to handle the endogenity for mlogit. My endogenous variables are two variables(each of them has two levels), and my number of observations is 4807. According to the...

View Article

Weighting before Multiple imputation

Hello, I have annual data from a cohort study since 2014 about smoking status. I would want to use the data (e.g., sex, age, self-rated health,...) of participants included in 2013 and calculate annual...

View Article

Changing matrix values based on values of STATA variable

Dear Statalist, I am currently running a random forest classification algorithm in STATA, and I wish to construct a cost function needed to run a weighted RF (using the crtrees algorithm). In order to...

View Article
Browsing all 73345 articles
Browse latest View live


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