cc

Average selling price for completed eBay items on each day of the week

Written
Topics

Here’s a bookmarklet to let you know what the average price of items shown in eBay was on each day of the week.

  1. Drag the link below to your bookmarks bar (or address bar).
  2. Navigate to a completed and sold page on eBay.
  3. Click on the bookmarklet.

It’s probably best to run it on a page with the max results as high as possible, and try it on a few pages. Also limit the page to display the most relevant items.

The eBayDayAvg bookmarklet showing average prices per day of the week in an alert box

Here’s the code:

eBayDayAvg Drag this link to your bookmarks bar.

msg = '';
days = ['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'];
items = {0:[],1:[],2:[],3:[],4:[],5:[],6:[]};
$('.sresult ').each(function() {
 title = $(this).find('.lvtitle').text();
 if (!(title.includes('fault') || title.includes('spare') || title.includes('issue') || title.includes('damage'))){
 price = parseFloat($(this).find('.lvprice').text().replace('£', ''));
 date = new Date(Date.parse($(this).find('.timeleft').text() + ' ' + new Date().getFullYear()));
 items[date.getDay()].push(price);
 }
});
for(item in items) {
 if (items[item].length > 0) {
 msg += days[item] + ': ' + items[item].reduce(function(a, b){return a+b;}) / items[item].length + '\r\n'
 }
};
alert(msg)

More like this