i have the data
----------------------- copy starting from the next line -----------------------
Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input str10 VDS_ID byte CO_NF_WORK double DIST byte WORK_DAYS double AVG_WORK_HRS long WAGES_CASH int WAGES_KIND long(AMT_SPENT WAGES_NET_INC) float(NF_DIST NF_WORK_DAYS NF_AVG_WORK_HRS NF_WAGES_CASH NF_WAGES_KIND NF_AMT_SPENT NF_WAGES_NET_INC)
"IAP10A0008" 20  0 10  8  1300    .    .  1300         0  227         8  29030     0     0  29030
"IAP10A0008" 21  0  6  6   400    .    .   400         0    6         6    400     0     0    400
"IAP10A0008" 25  0  6  6   660    .    .   660         0   27         6   2850     0     0   2850
"IAP10A0009" 21  0 10  6   500    .    .   500         0   10         6    500     0     0    500
"IAP10A0010" 12  0 31  5  2500    .    .  2500         0  544  5.277778  61410     0     0  61410
"IAP10A0030" 12  0 28  4  3000    .    .  3000         0  600       3.9  40700     0     0  40700
"IAP10A0034"  1 70 30 10  3500  500 2000  2000        70  334        10  45500  6000 18500  33000
"IAP10A0034" 20  0  7  8  1050    .    .  1050 23.333334   58         8   6380     0  1200   5180
"IAP10A0034" 25  0  2  6   220    .    .   220         0   14         6   1420     0     0   1420
"IAP10A0035" 12  0 30  6  3000    .    .  3000         0  576 4.1578946  43100     0     0  43100
"IAP10A0035" 15 70 25  8  6250    . 5000  1250        70  278         8  69500     0 55000  14500
"IAP10A0035" 18 70 22  8  2600    . 2000   600        70  284         8  31450     0 25000   6450
"IAP10A0038"  1 70 18  8  1440    . 1200   240        70  584         8  72520     0 59270  13250
"IAP10A0038"  3  0 26  6  2200    .    .  2200         0  259  5.916667  15100  7150     0  22250
"IAP10A0039" 21  0  5  6   400    .    .   400         0    5         6    400     0     0    400
"IAP10A0039" 25  0 12  6  1320    .    .  1320         0   64         6   6640     0     0   6640
"IAP10A0043" 12  0 30  5  2500    .    .  2500         0  309  5.090909  28100     0     0  28100
"IAP10A0043" 20  0 20  8  3000    .    .  3000         0   81  7.714286  10730     0     0  10730
"IAP10A0044"  1 10 25 10 12000    .    . 12000        10  254        10 137000     0     0 137000
"IAP10A0044" 12  0 28  6  5000    .    .  5000         0  849      4.75 101500     0     0 101500
"IAP10A0044" 25  0  2  8   300    .    .   300         0    2         8    300     0     0    300
"IAP10A0046" 20  0 12  8  1800    .    .  1800      13.5  166         8  31800     0     0  31800
"IAP10A0046" 25  0  2  6   180    .    .   180  6.666667   29         6   3170     0     0   3170
"IAP10A0048"  1 70 26  8  5500    . 2000  3500        70  298         8  66000     0 25500  40500
"IAP10A0053"  1 70 27  4  4000    . 4000     0  58.23529  450  5.882353  85200     0 48200  37000
"IAP10A0055" 12  0 31  2  2500    .    .  2500         0  364 4.0833335  49500     0     0  49500
"IAP10A0055" 24  0 15  8  7000    .    .  7000         0  144         8  69000     0     0  69000
"IAP10A0058" 19  0  4  2  3000    .    .  3000         0   41  2.833333  37000     0     0  37000
"IAP10A0081" 12  0 31  3  1700    .    .  1700         0  590      4.45  46400     0     0  46400
"IAP10A0082"  1 70 24  8  4000    . 3000  1000        70   73         8  12000     0  9000   3000
"IAP10A0082" 19  0  6  5   750    .    .   750         0   80  5.333333   9900     0     0   9900
"IAP10A0082" 20 70 28  8  6000    . 4000  2000  49.16667  232         8  54510  1600 24500  31610
"IAP10A0082" 25  0 14  6  1400    .    .  1400         0   83         6   8870     0     0   8870
"IAP10A0202" 19 20  7 10  1500    .    .  1500 13.333333   39        10   4500     0     0   4500
"IAP10A0202" 20  0  3  8   350    .    .   350         0    3         8    350     0     0    350
"IAP10A0202" 21  0  6  6   400    .    .   400         0    6         6    400     0     0    400
"IAP10A0202" 25  0  3  8   450    .    .   450         0    8         8   1200     0     0   1200
"IAP10A0203" 20  0 10  8  1500    .    .  1500         0   55         8   8310     0     0   8310
"IAP10A0203" 21  0 12  6  1000    .    .  1000         0   12         6   1000     0     0   1000
"IAP10A0203" 25  0  7  8  1000    .    .  1000         0   56         7   7280     0     0   7280
"IAP10A0208"  1 70 16 10  6000    .    .  6000        70  497        10 177500     0 44000 133500
"IAP10A0208" 12  0 31  2  1500    .    .  1500         0  568 3.3157895  42500     0     0  42500
"IAP10A0208" 25  0  8  6   800    .    .   800         0   36         6   3650     0     0   3650
"IAP10A0209" 12  0 30  6  3000    .    .  3000         0  506         4  37200     0     0  37200
"IAP10A0210"  1  0 31  6  1500    .    .  1500 23.333334  354  6.833333  15350  1200  3650  12900
"IAP10A0210"  4  0 17  2   450  250    .   700         0  225         2   5100  3550     0   8650
"IAP10A0210" 20  0  7  8   850    .    .   850         0  121         8  18250     0     0  18250
"IAP10A0212"  1 13 24  8  2760    .    .  2760      58.6  378       9.6  80625 17500 35000  63125
"IAP10A0212" 20  0  4  8   600    .    .   600         0   69         8   8690     0     0   8690
"IAP10A0217"  1 50 24  8  6000    .    .  6000        50  299         8  72000     0     0  72000
"IAP10A0217" 23  0 25  4  4000    .    .  4000         0  282 4.6666665 118000     0     0 118000
"IAP10A0220" 21  0  8  6   700    .    .   700         0    9         7    820     0     0    820
"IAP10A0220" 25  0 30  2   300    .    .   300         0 1025 4.0540543  32690     0     0  32690
"IAP10A0224"  1 70 24  8  6000    . 3000  3000        70   24         8   6000     0  3000   3000
"IAP10A0224" 12  0 30  6  3000    .    .  3000         0  688  3.708333  43600     0     0  43600
"IAP10A0224" 23  0 25  8  3500    .    .  3500         0  155         8  21250     0     0  21250
"IAP10A0225" 12  0 30  2  1000    .    .  1000         0  502  3.777778  33600     0     0  33600
"IAP10A0225" 20  0  5  8   750    .    .   750         0   23         8   3450     0     0   3450
"IAP10A0226" 12  0 28  5  2800    .    .  2800         0  330  2.818182  16500     0     0  16500
"IAP10A0227"  1 70 30  8  5000    . 1000  4000        70   30         8   5000     0  1000   4000
"IAP10A0227" 12  0 30  2  1200    .    .  1200         0  612 3.7142856  40600     0     0  40600
"IAP10A0227" 25  0 18  6  1800    .    .  1800         0   26  6.666667   2700     0     0   2700
"IAP10A0228"  1 10 25  8  2500    .    .  2500        10   75         8   7800     0     0   7800
"IAP10A0228" 21  0 10  6   750    .    .   750         0   10         6    750     0     0    750
"IAP10A0228" 23  0 30 10 10000    .    . 10000         0  343        10 121000     0     0 121000
"IAP10A0228" 25  0  2  6   200    .    .   200         0   43         6   4390     0     0   4390
"IAP10A0229" 20  0 15  8  1900    .    .  1900         0   30         8   3700     0     0   3700
"IAP10A0231" 12  0 31  6  5000    .    .  5000         0  271 3.4444444  24650     0     0  24650
"IAP10A0231" 19  0 22 10 10000    .    . 10000         0  184  8.666667  67000     0     0  67000
"IAP10A0231" 25  0 10  6  1000    .    .  1000         0   22         6   2200     0     0   2200
"IAP10A0232" 12  0 30  4  2500    .    .  2500         0  405  4.142857  47900     0     0  47900
"IAP10A0232" 20  0 15  8  2500    .    .  2500         0   52         8   8050     0     0   8050
"IAP10A0233"  1 70 30 10  4000 1500 2500  3000        70  270        10  44000 15000 30000  29000
"IAP10A0233" 18  0 15  8  1000    .    .  1000         0  102      6.25   6900     0     0   6900
"IAP10A0233" 20  0 18  6  1600    .    .  1600         0   18         6   1600     0     0   1600
"IAP10A0234" 20  0 12  8  1800    .    .  1800         0  166         8  23080     0     0  23080
"IAP10A0234" 25  0  9  6   900    .    .   900         0   94         6   9920     0     0   9920
"IAP10A0239" 12  0 31  3  1200    .    .  1200         0  495 3.9411764  37000     0     0  37000
"IAP10A0239" 25  0  7  8  1050    .    .  1050         0   18         8   2700     0     0   2700
"IAP10A0240" 12  0 30  3   800    .    .   800         0  481    3.9375  20500     0     0  20500
"IAP10A0240" 23 70 26 10  7500 3000 4500  6000        70  521        10 161800 56100 90500 127400
"IAP10A0241" 25  0 13  8  2000    .    .  2000         0   19         8   2900     0     0   2900
"IAP10A0297"  1 12 20  8  2000    .    .  2000        12   46         8   4600     0     0   4600
"IAP10A0297" 21  0  6  8   600    .    .   600         0    6         8    600     0     0    600
"IAP10A0299"  1 70 30 10  3500  700 1200  3000        70   55        10   7000  1400  2400   6000
"IAP10A0299" 20 70 22 10  7700    . 3500  4200  31.11111  144  8.888889  31090     0 10500  20590
"IAP10A0299" 25 70 28  6  2000  600 2000   600        70  142         6  10000  2750  9500   3250
"IAP10A0300"  1  0 29 10  4500  800    .  5300         0  354        10  50500  8610     0  59110
"IAP10A0300" 18  0  2  6   200    .    .   200         0    2         6    200     0     0    200
"IAP10A0301"  1 70 25 10  2000 1500 2000  1500        70  338        10  23000 17250 23000  17250
"IAP10A0301" 20 70 15  8  3750    . 2000  1750  46.66667  325       8.5  75310     0 31750  43560
"IAP10A0301" 21  0 15  6  1400    .    .  1400         0   15         6   1400     0     0   1400
"IAP10A0301" 25  0  6  6   660    .    .   660         0   15         6   1650     0     0   1650
"IAP10A0302" 20  0 14  8  1400    .    .  1400         0   31         8   3000     0     0   3000
"IAP10A0302" 25  0 18  6  1800    .    .  1800         0   38         6   3940     0     0   3940
"IAP10A0303"  1 12 26  8  2860    .    .  2860        12  323         8  33900     0     0  33900
"IAP10A0304" 12  0 28  5  5600    .    .  5600         0  698 3.9130435  60600     0     0  60600
"IAP10A0305"  1  0 30  6  3000  400    .  3400         0  286       5.6  27750  3100     0  30850
"IAP10A0305" 12  0 30  2  1000    .    .  1000         0  122         3   6000     0     0   6000
"IAP10A0305" 25  0  3  8   450    .    .   450         0    3         8    450     0     0    450
end
------------------ copy up to and including the previous line ------------------
and to reshape in wide format i used code as:
reshape wide DIST WORK_DAYS AVG_WORK_HRS WAGES_CASH WAGES_KIND AMT_SPENT WAGES_NET_INC, i(VDS_ID) j(CO_NF_WORK)
but i got error like :

Code:
 reshape wide DIST WORK_DAYS AVG_WORK_HRS WAGES_CASH WAGES_KIND AMT_SPENT WAGES_NET_INC, i(VDS_ID) j(CO_NF_WORK)
(note: j = 1 2 3 4 5 6 7 8 10 11 12 14 15 16 17 18 19 20 21 22 23 24 25)
variable NF_DIST not constant within VDS_ID
variable NF_WORK_DAYS not constant within VDS_ID
variable NF_AVG_WORK_HRS not constant within VDS_ID
variable NF_WAGES_CASH not constant within VDS_ID
variable NF_WAGES_KIND not constant within VDS_ID
variable NF_AMT_SPENT not constant within VDS_ID
variable FARM_WAGES_NET_INC not constant within VDS_ID
    Your data are currently long.  You are performing a reshape wide.  You typed something like

        . reshape wide a b, i(VDS_ID) j(CO_NF_WORK)

    There are variables other than a, b, VDS_ID, CO_NF_WORK in your data.  They must be constant within VDS_ID because
    that is the only way they can fit into wide data without loss of information.

    The variable or variables listed above are not constant within VDS_ID.  Perhaps the values are in error.  Type
    reshape error for a list of the problem observations.

    Either that, or the values vary because they should vary, in which case you must either add the variables to the list
    of xij variables to be reshaped, or drop them.
r(9);
please help me to sort out this issue