I started reading Anthony Trollope's The Eustace Diamonds, which is about the machinations of a very wealthy and dishonest and villainous widow. And I love her. She's pretty much the best. But Trollope does not love her. He's constantly talking about how evil she is and shit.
In fact, lots of Victorian novels are about very evil characters, and they always have this very moralizing tone. For instance, Vanity Fair's Becky Sharp has to be one of the most vivid characters in literature, but Thackeray clearly very much disapproves of her and is constantly giving you these sly little asides (an authorial intervention that was much more allowable in Victorian literature) about how awful and unfeeling she is.
But I don't believe him. Thackeray constructed the novel. He chose to write her. I don't see how a person could write an entire novel about Becky Sharp without, in some way, thinking that she is awesome. In some ways, I feel like he just inserted the judgmental tone so that his audience would let him get away with writing the novel. It's like how you can write a crime novel about a character who gleefully kills and steals and cheats and rapes...as long as they get their comeuppance in the end.
Personally, many of my protagonists are awful people. I don't really intend them to be that way; it's more that I just don't think about morality when I'm writing, which means that all my work exists in a pretty amoral universe. I would never consider having a character not do something because it's "not the right thing to do." But I've learned to disguise that, and to play tricks on the reader in order to artificially build sympathy. For instance, if you put the protagonist in a pitiable situation, they'll come off more sympathetic. And if you have them do something good for someone early on in the story, then the reader will give them leeway. And if there's a perception that the protagonist is fighting against some greater societal evil, that can also help (this is often the reason why crime novels get a free pass, for instance).
But, to me, all of that stuff is just tossed in because, for some reason or another, most readers can't sympathize with characters that are not, in some way, good.
For instance, at AWP, I was talking to someone about that interview in which Claire Messud talked about how she didn't think characters need to be likeable. In that interview, the primary character under discussion was Nora in Messud's The Woman Upstairs. And I have to say...I didn't find her unlikeable at all. I sympathized intensely with her feeling of being abused and toyed with and ignored. And so what if those feelings mostly came out as inchoate rage? What's wrong with that?
What I think people ignore about "unlikeable" characters is how likeable they actually are. For instance, I found myself dazzled by Scarlett O'Hara and Humbert Humbert. They're amoral wretches, but they're actually exactly the sort of people that one would want to be friends with, because they seem like they're charismatic and they always have something to say.
Actually, Scarlett O'Hara is one of my favorite characters, because rarely has there been a heroine with fewer redeeming characteristics. And yet the novel revels in her. She doesn't really come in for much, if any, oppobrium. If anything, the novel gradually reveals that Ashley Wilkes and Melanie whatserface are hothouse flowers who can't really exist outside without the privileges accorded them in the antebellum south. And Scarlett comes out looking pretty good in the end. Her ruthlessness, the book argues, is exactly what a person needs to have if they're going to survive.
The mark of a good writer, I think, is that meaning comes through even when you don't intend it to. Take Dickens, for instance. He wrote the broadest characters imaginable, but sometimes you can't really tell whether they're scoundrels or not. Take Mr. Micawber for instance. He's perpetually penurious, and he constantly borrows money without intending to pay it back. His family suffers because of his flightiness. And he eventually ends up transported to Australia. But he still gets a very loving portrayal in David Copperfield. And, in the end, it's hard to say whether he's a hero or a villain.
Still, there's a level of esotericism there. I don't think that most readers are sophisticated enough to hold opinions about a character that are different from what the book tells you. Most readers will say that Mr. Micawber is a great guy, and that Harold Skimpole (from Bleak House) is awful, even though the two characters are pretty much exactly the same, because Dickens tells you that one is good and that the other is bad.
So when you're writing a book, you have to determine a surface interpretation of the character (will I portray them sympathetically or unsympathetically?) and then allow the opposite interpretation to remain buried in the text, for the benefit of readers who care to dredge it up. And somewhere in the intermingling of the two interpretations, you end up with a more complex and true portrait of a person.