updated total calc
doc update
better totals
added extra output for innerdist
arg issue
write a string, not an int