# Created by Matt Asher for statisticsblog.com # Feel free to share and modify so long as this header remains playlist = read.table("/path/to/playlist.txt", sep="\t") pTable = data.frame(table(playlist[,1])) pTable = pTable[ order(-pTable[,2]),] HTMLfile="/path/to/save/popchart.html" toWrite = '
' toWrite = paste(toWrite, "| ') toWrite = paste(toWrite, ' | ', sep="") toWrite = paste(toWrite, pTable[m,1], "\n") toWrite = paste(toWrite, '') toWrite = paste(toWrite, ' | |