When someone is caught committing a crime (mainly one sexual in nature, but can refer to all crimes), with overwhelming evidence to prove they did it; in their defense, the culprit denies that they were the one caught doing the crime.
Derived from the Shaggy song "It Wasn't Me", which describes a man being caught having sex with another woman by his wife, and subsequently denying that it was him she actually saw.
When caught on video having sex with a 14 year old girl, R. Kelly employed the Shaggy Defense; he just denied that he was the one in the video.
An individual who enjoys learning and does not adhere to social norms, however, they carry themselves in a bold and confident manner. The person who does not fit the prototypical definition of "being cool", but is still a trend setter and doesn't care what other people think and goes against the grain.
He scored the highest test scores and he is still the strongest player on the football team, he is such a swaggy nerd.