I want to rename all variabls.
----------------------- copy starting from the next line -----------------------
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(reg1 reg2 reg3 reg4 reg5) 6.027092 .0002930561 5.720574 .000030197365 5.421104 -.3271553 .0008169214 -.310192 .00011717257 -.2936188 -1.4716898 .8026103 -1.308212 .7873334 -1.1484942 -3.0507104 .6398486 -2.891255 .5903057 -2.735466 .5084921 .7445467 .4553375 .723156 .4034053 .2120345 .5455699 .26072997 .36693245 .3083055 .12750722 .5204554 .1125301 .4911 .09789742 -.13111551 .59331024 -.15305555 .4491424 -.174491 .05691987 .5425936 .06356363 .4090695 .07005459 end
Code:
ds local oldname = r(varlist) di "`oldname'" **reg1 reg2 reg3 reg4 reg5 di `oldname' **6.027092.000293065.7205739.00003025.4211044 local newnames "x1 x2 x3 x5 x6" rename (`oldname') (`newnames') rename ("`oldname'") ("`newnames'") /*Not working*/
Thanks very much.
Bests,
wanhai
0 Response to Question about double quotes
Post a Comment