Re:Spam Hits Lowest Levels Since 2008 (Did You Notice?)
by Morendil on Wednesday June 29, 2011 @04:17PM
(#2711074)
It's per-month, not per-day - GMail only stores 30 days' worth of email in the Spam folder.
As to how - cron job on my server querying GMail via IMAP. Source below. Manually copy and paste the resulting text file to a GDoc spreadsheet; use the Time Series widget to generate the chart.
require 'net/imap'
require 'date'
imap = Net::IMAP.new('imap.gmail.com',993,true)
imap.login('yourlogin','yourpwd')
msgs = imap.status("[Gmail]/Spam",["MESSAGES"])["MESSAGES"]
puts Date.today.to_s + "\t" + msgs.to_s
Also how do you automate the counting and storing it in the spreadsheet? I think that's pretty damn cool.