Quoted:
As someone else said, a shotgun is for killing birds, and opening doors.
In a defensive role, there's nothing a shotgun does that a rifle cant do better.
Except maybe shoot buckshot, my AR does not shoot buckshot worth a damn. I think there is no difinative answer as to which is better for defense, shotgun or carbine. It comes down to what you can personally do with your chosen weapon. 9-30 caliber projectiles with a single pull of the trigger is fairly effective at stopping a threat. With the AR or similar weapon you have a higher magazine capacity and a higher velocity projectile.
If you believe in compromise, get yourself a Saiga with a 20 round drum. Then you have 12 gauge power with carbine capacity. Personally, inside the house, I am going to have a handgun. Capacity, manuverability, speed and retention are all strong points of the handgun. To each their own though, bottom line is you need to be able to rounds on target with whatever you decide to use.