Hello Karina,
Sorry for your struggle with R. Don´t give up!
First:
If you want to receive better help from the community, you should provide a reproducible example (reprex), so people can troubleshoot your problem.
there is also a nice R package that helps you to create reprex:
Second:
back to your problem, from you errors, it seems that the code does not recognize the column name you are trying to plot (undefined columns selected). It does seems that your data have strange characters as column names like ú and .. Try correcting the column names in you train.data and run again the code.
If you want to do that automatically, and not manually, you can use the awesome "janitor" package
which has a sweet clean_names() function that automatically makes all the column names readable by R.
As a wild guess, I would do this:
library(janitor)
library(tidyverse)
toplot <- train.data %>% clean_names()
and then substitute the corrected names in your code like:
qqplot(toplot, aes(newnamecolumn1, newnamecolumn2)) + geom_point() + stat_smooth()
I am sorry but without a reproducible example, i cannot help you further.
Good luck!