RAM, from a computer, will not contain anything once power is removed from it. It would have been impossible to get a virus from a stick of RAM.
Even when power is still applied, RAM requires a refresh. Without that refresh (driven by the CPU), the RAM will start losing what it had contained within seconds.