You're correct. The militia is the people, back then defined as able-bodied males capable of using arms. Supreme court decisions have for that reason always upheld that point.
It's an individual right as clearly as any other in the bill of rights from free speech to peaceable assembly to any other. Only the illiterate don't get this.