TIP31A Transistor Help

but I'm not sure how to choose the resistor on the base.

Choose it such that the base current is at least the collector current divided by the transistor's gain. Then give it a bit of margin by halving it.