Viva!
Penso que seja isto que você procura:
var tmp = new Array("1","2","3","4");
var color = new Array("red", "green", "blue", "yellow");
var myvar;
var i = 0;
setInterval(function() {
$( "#right" ).text(tmp.shift());
$( "#right" ).css("background-color", color.shift());
}, 5000);
#right {
position: relative;
float: left;
margin: 0 5px 0 0;
border: 1px solid black;
width: 200px;
height: 200px;
overflow: hidden;
}
div.panel {
position: absolute;
height: 100%;
width: 100%;
display: none;
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div id="right">
</div>