To suppress warnings in the global settings, you can use the warn option in options function as follows:
options(warn=-1)
To temporarily suppress warnings in global settings and turn them back on, use the following code:
defaultW <- getOption("warn")
options(warn = -1)
[YOUR CODE]
options(warn = defaultW)
If you want to explore more in R programming then watch this R programming tutorial for beginner: