Hi, I am trying to do this in RStudio but it keeps telling me that there is an error: unexpected ' } ' in " } ". I checked all the parenthesis for any mistake but I believe they are well used. I am new to R so any help is welcome.
Hi Trini
The problem isn't with the curly bracket itself, it's the other brackets. You have 11 open brackets "(" and only 10 close brackets ")" so R gets confused when it encounters the curly bracket!
Hope that helps!
Clare