Add function countByValue() and countByKey().

Yeah - we can put combineByKey, reduceByKey etc. in the new file. I've created https://sparkr.atlassian.net/browse/SPARKR-137 for this