Sorry, this should be simple.
I typed for the variable votefentanyl1new
. fre votefentanyl1new
votefentanyl1new
-----------------------------------------------------------
| Freq. Percent Valid Cum.
--------------+--------------------------------------------
Valid 1 0 | 71 8.18 14.06 14.06
2 1 | 289 33.29 57.23 71.29
3 6 | 132 15.21 26.14 97.43
4 9 | 13 1.50 2.57 100.00
Total | 505 58.18 100.00
Missing . | 363 41.82
Total | 868 100.00
-----------------------------------------------------------
. recode votefentanyl1new (0 = 9)
(votefentanyl1new: 0 changes made)
. replace votefentanyl1new = . if votefentanyl1new == 9
(0 real changes made)
. dataex votefentanyl1new in 1/30
----------------------- copy starting from the next line -----------------------
------------------ copy up to and including the previous line ------------------
Listed 30 out of 868 observations
Why can;t I replace the values of votefentanylnew? Thanks for any help
Ric Uslaner
I typed for the variable votefentanyl1new
. fre votefentanyl1new
votefentanyl1new
-----------------------------------------------------------
| Freq. Percent Valid Cum.
--------------+--------------------------------------------
Valid 1 0 | 71 8.18 14.06 14.06
2 1 | 289 33.29 57.23 71.29
3 6 | 132 15.21 26.14 97.43
4 9 | 13 1.50 2.57 100.00
Total | 505 58.18 100.00
Missing . | 363 41.82
Total | 868 100.00
-----------------------------------------------------------
. recode votefentanyl1new (0 = 9)
(votefentanyl1new: 0 changes made)
. replace votefentanyl1new = . if votefentanyl1new == 9
(0 real changes made)
. dataex votefentanyl1new in 1/30
----------------------- copy starting from the next line -----------------------
Code:
* Example generated by -dataex-. For more info, type help dataex clear input long votefentanyl1new 2 3 2 2 3 1 2 1 2 2 4 2 2 2 2 3 2 2 3 1 1 2 3 1 1 2 2 2 4 2 end label values votefentanyl1new votefentanyl1new label def votefentanyl1new 1 "0", modify label def votefentanyl1new 2 "1", modify label def votefentanyl1new 3 "6", modify label def votefentanyl1new 4 "9", modify
Listed 30 out of 868 observations
Why can;t I replace the values of votefentanylnew? Thanks for any help
Ric Uslaner

Comment