score:0

var xaxis = d3.svg.axis()
        .scale(x)
        .orient("bottom")
        .tickformat(function(d) {
        var minutes = math.floor(d / 60000);
        var seconds = +((d % 60000) / 1000).tofixed(0);
        return (seconds == 60 ? (minutes+1) + ":00" : minutes + ":" + (seconds < 10 ? "0" : "") + seconds);

});

this will convert milliseconds to minutes and seconds.

score:3

here's the answer for posterity (when you set the date, it should be relative to when you're initializing your other date objects, if necessary):

var xaxis = d3.svg.axis()
        .scale(x)
        .orient("bottom")
        .tickformat(function(d) {
            return d3.timeformat('%-m')( new date(0).setseconds(d) ) # formats minutes
        });

Related Query