My dataframe looks like this:
location eco
Germany eco
Netherlands eco
USA not-eco
Dubai not-eco
I would like to create a new column in the dataframe and display TRUE if the location is "eco" and display FALSE if location is "not-eco". The result should look like this:
location eco logical
Germany eco TRUE
Netherlands eco TRUE
USA not-eco FALSE
Dubai not-eco FALSE
How to do this with R?