Now I see... 
Without specifying that you do not have the sudo right the question seemed rather basic, no offense meant.
I believe it could be installed via
apt-get download grass
dpkg -i grass_7.4.0-1_all.deb --force-not-root --root=$HOME
Note that while this does work on my Ubuntu machine I do not have access to rstudio-cloud, so I can not test it directly