This is an incredibly simple question. If I have a variable defined by a word such as:
variable1 = 'returns'
This would be something that I could later edit (i.e. change 'returns' to 'revenue').
I then want to execute a particular block of code provided that the variable is 'returns'. Why does R tell me that I cannot use an = sign when I try:
if(variable1 = 'returns'){
#code would go here
}