Connecting postgresql database with R

Using this code
con_1 <- dbCanConnect(RPostgreSQL::Postgres(),
host = "my company adress",
dbname = "sample1",
port = 5432,
user = "my user name",
password = "company db pass")

can't connect to the database of the company with R. Tried with creating separate DSN but still error DSN not found. The database i can see in my pgadmin but cant connect here.

Can you provide more details about your problem? A detailed error message might be helpful, right now we don't have enough information to help you out.