If you don't have something hooked to the other input pins of PORTA, they are floating and will return an unknown value. This is considered bad practice for many reasons. Strap unused inputs to Vdd through a resistor is the preferred method. If you are not using the other ports, you can set them to output 0.