In order to do the calculation, you have to read the current value from the ini file.
Code:
on *:text:*:#:{
var %words = $readini(stats.ini,n,words,$nick)
var %lines = $readini(stats.ini,n,lines,$nick)
if !%words { var %words = $numtok($1-,32), %lines = 1 }
else { 
inc %words $numtok($1-,32)
inc %lines 1
}
.writeini stats.ini words $nick %words
.writeini stats.ini lines $nick %lines
if ($1 == !stats) && (!$2) {
.msg $chan $nick $+ 's Stats: %words words ( $+ $round($calc(%words / %lines),2) words per line $+ )
}
}
 


I put in the variables, rather than leaving the direct access coding, which you were using, due to the fact that using the variables means the information comes from ram, rather than having to be read from the hard drive each time. This is a faster method, and also means that your hard drive isn't accessed as often, extending the life of your drive.