It wasn't a masterpiece. It may have been interesting and rather entertaining, but calling Code Geass a masterpiece is like calling American Idol a work of art. There's a large difference between entertaining and masterpiece, and calling it such is an insult to the truly great ones, issues of taste aside. Calling it a "masterpiece" implies that is among the best anime ever created, and that's giving it far more credit than it deserves. Even if we only look at mystery, action, sci-fi, drama, or mecha anime, there are still dozens of better choices.
I don't get bothered if people say they think something is "good" or that they enjoyed something, because that's an issue of taste. However, when you start throwing the word "masterpiece" around, you're going beyond the realm of personal enjoyment and into the realm of critical discussion, and Code Geass doesn't stand up well in that department, especially compared to other series.
Here's a guide to some of the more popular series. I recommend watching many of the series in the "mystery," "action," "drama," "mecha," and "sci-fi" genres before making such claims.