Add a box. Drop it on the ground. Then double-click the material and create a new material by clicking the bottom right NEW button.
Go to the Colors tab and double-click the black to white gradient to choose another one. Choose the Red green blue from the Colorful collection.
Click the options button and change Preview Options to Cube
Click the Function Output Obsever button.
Now drag the small connector line upwards onto the Texture Map node. When it connects, a menu will popup, choose 'Grayscale Output'.
You're now ready to render your gradient. You can change it anytime by choosing or creating a new gradient in the color map of the Colors tab in the Advanced Material Editor.