I want to add the two numeric variables (strike1 and boycott1) together to get a 'protest' variable that accounts for each type of protest. To give an example, the first value on this new variable should be: 2:3598. I have used the method below on other variables and it worked, does anybody know what might be happening this time that it is coming out different?
>table(strike
strike
Not at all Once Twice
2055 2555 840
Three times . More than three times
383 605
> table(boycott)
boycott
Not at all Once Twice
1543 2139 625
Three times . More than three times
214 426
> strike1<-as.numeric(strike)
> boycott1<-as.numeric(boycott)
> table(strike1)
strike1
1 2 3 4 5
2055 2555 840 383 605
> table(boycott1)
boycott1
1 2 3 4 5
1543 2139 625 214 426
> protest<-strike1+boycott1
> table(protest)
protest
2 3 4 5 6 7 8 9 10
604 284 895 179 193 124 72 38 93
> table(strike1, boycott1)
boycott1
strike1 1 2 3 4 5
1 604 154 31 10 35
2 130 843 83 16 19
3 21 83 98 24 13
4 3 37 45 36 12
5 7 36 23 26 93