This radar view of asteroid 2011 UW158 was captured by scientists using the Arecibo Observatory, a huge radio telescope, during the space rock's flyby of Earth on July 19, 2015. The asteroid approached within 1.5 million miles of Earth.

When an asteroid packed with about $5 trillion worth of platinum zoomed past Earth this month scientists were ready, capturing the space rock on radar as it sailed safely by our planet.

The asteroid 2011 UW158 missed Earth by about 1.5 million miles (2.4 million kilometers) — a little more than six times the distance between the planet and the moon — during its flyby on July 19. There was never a chance of a collision during the flyby, researchers said. But it was close enough for NASA scientists to create a video of the asteroid from radar observations.

The near-Earth asteroid is an intriguing candidate for mining, said representatives of the company Planetary Resources, which is hoping to begin these activities in the coming decades. (On July 16, Planetary Resources' Arkyd 3 Reflight spacecraft was deployed from the International Space Station to test software, control systems and avionics that could be used for asteroid hunting.) [Asteroid Mining: Planetary Resources Plan in Pictures]

Previous studies by Planetary Resources estimated that 2011 UW158 contains about $5.4 trillion worth of platinum, an element that is rare on Earth.

These three separate radar images of asteroid 2011 UW158 show how the asteroid was tumbling as it flew by Earth on July 19, 2015. (Image credit: Courtesy of the NAIC - Arecibo Observatory, a facility of the NSF)

The company aims to mine asteroid metal eventually, but the group's initial focus is on space rocks that are laden with water. Mining these types of asteroids, which are known as carbonaceous chondrites, could open up the solar system to exploration by providing a relatively cheap and easily accessible source of spacecraft propellant, advocates say. (Water can be split into hydrogen and oxygen, the chief components of rocket fuel.)

"The problem is, sending [Earth's] water into space is extraordinarily expensive, and even if the launch was free, it takes an incredible amount of energy to shift that stuff around," Planetary Resources president and chief engineer Chris Lewicki said during a Sunday webcast about the "trillion-dollar asteroid" hosted by the Slooh Community Observatory, which provides live broadcasts of celestial events.2011 UW158 is about 2,000 feet long and 1,000 feet wide (600 meters by 300 meters), according to observations made by the Arecibo Observatory in Puerto Rico. Arecibo imaged the asteroid in detail for the first time on July 14, allowing astronomers to discover that the rock has a very odd shape — kind of like an unshelled walnut — and is spinning very fast, completing one revolution every 37 minutes.

Unlike most asteroids, which are more like loose collections of pebbles and ice, 2011 UW158 may be a solid body.

"Its size, shape and rotation suggest there is something more than gravity holding this object together, or else the asteroid would break up due to its fast spin," observation leader Patrick Taylor, a scientist in Arecibo's planetary radar department, said in a statement.

The asteroid won't fly by Earth again until 2108 and is not considered a potential threat to the planet, researchers said.

Follow Elizabeth Howell @howellspace, or Space.com @Spacedotcom. We're also on Facebook and Google+. Original article on Space.com.