Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: RE: Date: Sun, 7 Feb 2010 21:41:16 +0100


From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: RE: Date: Sun, 7 Feb 2010 21:41:16 +0100
Date   Sun, 7 Feb 2010 21:59:38 +0100

<>

The error means what it says, I am afraid. Play around with the -expand-
line in this code to see where the limits for the -j()- variable are:


*******
vers 10.1
clear*
set obs 10

gen id=_n
expand 3200
bys id: gen year=_n+79

gen inc=rnormal(15000,7000)
 
reshape wide inc, i(id) j(year)

*******


HTH
Martin

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Mark Baerthel
Sent: Sonntag, 7. Februar 2010 21:41
To: [email protected]
Subject: st: Date: Sun, 7 Feb 2010 21:41:16 +0100

Dear Stata Community,

I always get the error r(134) when I try to reshape!
What can I do ?
Anything conceptually wrong with my commands ?
>>
. sum

    Variable |       Obs        Mean    Std. Dev.       Min        Max
-------------+--------------------------------------------------------
        date |     32494     14804.6    105.3298      14640      14973
      permno |     32494    65554.46    23142.46      10051      92866
         ret |     32494    .0081212    .1509227  -.8353909          3

. reshape wide permno, i(date) j(ret)
ret takes on too many values
r(134);
<<<

ret takes on too many values
r(134);


Thank you so much, 

Mark

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index