What is the purpose of the howMany integer in the wire.onReceive() function from the example code?
It tells you how many bytes have been received, and consequently how many you can read with Wire.read(). 

Before you have read anything with Wire.read() Wire.available() will return the same value.  As you read from the buffer Wire.available() will decrease, but howMany will stay the same.