When I try to start my bike I hear a chattering noise
Most likely there is just enough juice left in the battery to actuate the starter relay (solenoid), but not enough to turn the motor itself. That is your clicking noise. This happens to cars, too.
Other things you can check: Make sure that the screws holding the cables onto the battery are snug. If the battery and its connections are okay, then try this: Get someone more mechanically knowledgeable to carefully stick a screwdriver across the starter relay main leads; don't touch the metal part of the screwdriver, though. If the motor turns over fine, then check the starter button itself. If the contacts in the starter button are blackened/corroded, clean them off. A pencil eraser works well for this.
There are many other possibilities, but these are three good ones.
There are actually two relays that help send current from your thumb to the starter. There's a relay in the junction box and a solenoid down by the starter. The one you hear flapping with a dead battery is the relay in the junction box. It sounds like it's coming from under your right thigh, slightly toward your rear.
The solenoid (usually everyone calls it a starter relay) is part #27010-1213 SWITCH,MAGNETIC, and is shown here as 27010. The hot wire goes from that to the starter.
If the engine will not rotate when attempting to start, and there is a click or chatter, the most common cause of this is a discharged battery.
Here's what is happening: When you hit the starter button, it completes a low-current circuit to the starter solenoid. Your battery is low on charge, but it's got enough juice to manage this task. The solenoid doesn't create much of a voltage drop. The solenoid "flips", and the contacts inside are smacked together, making a sound and also completing the high-current circuit to the starter motor. At this juncture, if your battery was fully charged, the starter would begin to rotate, making a noise of its own and masking the "click" or "slap" that the solenoid makes.
Since, in this example, your battery is weak, it is up to the task of flipping the solenoid but is not up to the task of rotating the starter. All of the OOMPH that the battery has left gets sucked up by the starter motor. This creates a voltage drop so drastic that the solenoid doesn't get enough power to stay closed, so it is forced back open by the spring inside. When the solenoid contacts open up, the starter motor ceases to draw power and battery voltage recovers. Now the battery has enough power available to close the solenoid again. So it does. Cycle complete.
This cycle repeats rapidly for as long as you have your finger on the starter, or until the battery drains even further to the point that it cannot even work the solenoid any more. The sound that the solenoid makes, repeated rapidly and not masked by the starter, sounds like a clattering noise.
Cars with semi-dead batteries do the same when you turn the key to start.
The starter motor actually starts to rotate, and thus make noise, slightly BEFORE the solenoid contacts click. So the solenoid "click" is really well-masked under normal circumstances. This is due to electrical arcing. The current that the starter draws is so great that it can jump the air gap between the contacts just slightly before they actually close completely. This is the reason for a solenoid. A simple switch would not open far enough to prevent the starter motor from drawing the current across the gap.