Fictional characters do not have Socionics types as they do not metabolize information.
However, when a fictional character is based on a real person (who does metabolize information), the character may posses traits similar to that person. The character's mannerisms and reactions may correlate so well with the real person that they could be said to be a portrayal of that type.
The primary problem is that most fictional characters are designed to be entertaining, so their behavior is rarely identical to that of actual people. The more entertaining and less realistic a character is, the less that character's behavior is going to correspond with actual people and therefore actual types.
Also, when the fictional character is being portrayed by an actor or actress, that person's type will influence the overall impression we have of the character.