Reputation: 167
I am getting the following error for the code: Error: unexpected '}' in "}"
csv_etl <- function(client) {
if (client = 'OXF') {
print('I am OXF')
}
}
Is my syntax incorrect? I've counted the curly braces and parenthesis and they all are closed.
Upvotes: 0
Views: 37
Reputation: 9705
Use a double equal sign:
csv_etl <- function(client) {
if (client == 'OXF') {
print('I am OXF')
}
}
Upvotes: 2