Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: st: Binary Variables
Natalie Trapp <firstname.lastname@example.org>
Re: st: Binary Variables
Wed, 02 Jun 2010 18:41:51 +0200
Thank you very much to all of you for helping me!!
Well, I will try explain the problem again:
First I generated the dummy variables:
.encode region, generate (REGION)
. generate SchleswigHolstein= REGION if REGION == 1
(43657 missing values generated)
. replace SchleswigHolstein=0 if SchleswigHolstein== .
(43657 real changes made)
. generate Saarland= REGION if REGION == 2
(43918 missing values generated)
. replace Saarland=1 if Saarland== 2
(119 real changes made)
Then, I regressed the models:
. reg fertilisers_Var Saarland Brandenburg MeckPomm Sachsen
SachsenAnhalt Thueringen IleDeFrance Champagne Picardie HauteNormandie
Centre BasseNormandie Bourgogne NordPasDeCalais LorraineAlsace
FrancheComte PaysDeLaLoire Bretagne PoitouCharentes Aquitaine
MidiPyrenees Limousin RhonesAlpes Auvergne LanguedocRoussillon
ProvenceAlpesCote Corse ValleDAoste Piemonte Lombardia Trentino
AltoAdige Veneto FriuliVenezia Liguria EmiliaRomagna Toscana Marche
Umbria Lazio Abruzzo Niedersachsen Molise Campania Calabria Puglia
Basilicata Sicilia Sardegna Belgium Vlaanderen Wallonie Luxembourg
Netherlands Denmark Ireland EnglandNorth EnglandEast EnglandWest Wales
Scotland NorthernIreland MakedoniaThraki IpirosPeoponissos Thessalia
StereaEllas NRW Galicia Asturias Cantabria PaisVasco Navarra LaRioja
Aragon Cataluna Baleares CastillaLeon Madrid CastillaLaMancha Valencia
Murcia Extremadura Andalucia Canarias Hessen EntreDouroEMinho
TrasOsMontes RibatejoEOeste AlentejoEDoAlgarve Acores Austria EtelaSuomi
SisaSuomi PohjanmaaRheinlandPfalz PohjoisSuomi Slattbygdslan
SkogsOchMellan LanINorra Czech Estonia KoezepMagyarorszag KoezepDunantul
NyugatDunantul DelDunantul EszakMagyarorszag EszakAlfoeld DelAlfoeld
Latvia Lithuiana PomorzeAndMazury WielkopolskaAndSlask
MazowszeAndPodlasie BadenWuerttemberg MalopolskaAndPogorze Slovakia
Slovenia Bayern ClimateVariables Oats Barley Rye Wine *(and many more
Crops and Variables)*
Thank you very much once again for your patience and kind assistance,
On 6/2/2010 4:14 PM, Neil Shephard wrote:
On Wed, Jun 2, 2010 at 2:03 PM, Natalie Trapp<email@example.com> wrote:
I use Stata 11 and do a normal OLS estimation (with the "reg" command):
y = dependent variable (agricultural inputs)
x = independent variables (climate variables, crops, etc.) and dummy
variables that represent the 150 regions within the EU
This is _not_ showing what you are typing, if you are using -regress-
then I would expect you to have included something along the lines
regress agricultural_inputs temperature crops i.region
The coefficients of the dependent variable within each region are very
divers and significant for about 120 regions.
My Problem is for instance, when "Schleswig Holstein" is my reference
group, Stata adittionally omits Valle d'Aoste, Vlaanderen and Ile de France.
Could it be that there is missing data within your data structure such
that most observations for these regions are omitted and the few that
remain all have the same value of "agricultural_inputs".
Still, I don't quite understand why Stata does it, because the regions
(Germany, France, Netherlands) do not seem to be similar to me.
"Seems" is a vague term and is based on your subjective interpretation
of what you are expecting, and it need not be because you have the
data, you can look at it. Check the patterns of missing data that
exist and how these pan out within the regions, in particular those
that are being omitted.
Stata will be omitting them for a reason (and it will often indicate
why a particular category has been dropped).
So again, pasting the _exact_ command you are entering and the
resulting output would be very informative to other list members. You
can copy and paste from the Results window directly into an email.
* For searches and help try: