Shaun Nichols attempts to offer an explanation for this and other similarities in his paper "Imagining and Believing: The Promise of a Single Code". I'm having a pretty hard time seeing how his explanation is supposed to work.
The explanation Nichols offers, citing his previous work with Steve Stich, is that imagination and belief are distinct propositional attitudes with distinct functional roles, but that the propositional contents of each are given by representations in the "same code". What exactly does this mean? Nichols and Stich write:
One possibility that we find attractive is that the representations in the PWB ['possible worlds box' or 'imagination box'] are in the same "code" as representations in the Belief Box. The idea is that, although pretense representations are functionally distinguished from beliefs, there is an important sense in which they are similar. First, whatever determines the representational (or semantic) properties of representations in the Belief Box also determines the representational properties of representations in the PWB, and it does this in the same way in both cases. More importantly for our purposes, if pretense representations and beliefs are in the same code, then any processing mechanisms that work on the representations in the Belief Box and in the PWB will treat tokens of the two in the same way.
So here are the two claims.
(1) Imagination and belief are distinct propositional attitudes which differ by virtue of functional role. They are not distinguished by what contents they take; in each case, a subject has an attitude toward the proposition that p by virtue of having a syntactic string representing the proposition that p playing the characteristic functional role in the subject's cognitive life. And the semantic and syntactic properties by virtue of which strings represent propositions do not vary by propositional attitude; if a bit of syntax in the 'imagination box' represents that p, then so does the same bit of syntax in the 'belief box'.
(2) If a cognitive mechanism takes as its input propositions from either the belief box or the imagination box, its output will not depend on which box it came from.
It's not clear that Nichols and Stich thought of it this way in the quoted passage above, but I suggest we think of (1) as a statement of the Single Code thesis itself; (2) is suggested, rather plausibly, to follow from (1). It follows from (1) because the mechanisms in question can be represented as functions from propositional inputs to whatever outputs; (1) says that imagination and belief have the same kinds of contents, so a mechanism that takes contents of each as its sole input will not vary its output according to which box supplied the input. The mechanism itself doesn't know, so to speak, where the input came from, because the input is just a syntactic string that could happily sit in either box.
All this seems pretty plausible. But I don't see that it gets us very close to explaining the functional similarity of belief and imagination. Nichols writes:
In consuming fiction, one (or one's cognitive mechanisms) constructs a set of representations in one's pretense box. ... The representations being put into the pretense box are distinguished from beliefs by their functional roles, but they are not systematically distinguished from beliefs in terms of content. As with imagination generally, the pretense representations generated by fiction are in the same code as beliefs. In consuming fiction, then, the inferential systems process the pretense representations much as the inferential systems would process isomorphic beliefs.
On the single-code hypothesis, if a mechanism takes pretense representations as input, that mechanism will process the pretense representation much the same was it would process an isomorphic belief. This should apply to emotional systems as well as inferential systems. According to the single-code hypothesis, then, the emotional systems will respond to pretense representations much as they do to parallel beliefs.
I'm pretty sure this is wrong.
What we want to explain is why believing that p has similar effects to imagining that p; the Single Code thesis says only that in each case, one tokens, in various functional roles, identical syntactic strings. That's not enough to explain the phenomenon in question. One easy way to see why this is so is that the same will be true of any distinct propositional attitude. For example, desire, like imagination, is a propositional attitude that is distinguished from belief not by its content but by its functional role. One can token a sentence expressing that p in one's desire box, belief box, or imagination box. Desire, imagination, and belief are all in a single code. But desiring that a great injustice has been committed wouldn't make me feel angry, the same way I'd feel if I believed a great injustice has been committed. So, contrary to Nichols's claim, the Single Code thesis just doesn't predict the phenomenon Nichols sets out to explain.
You might think that (2) establishes relevant similarities, but you'd be wrong. (Remember, the version of (2) linking belief to desire follows from the corresponding (1), too.) What (2) says is that if a mechanism takes a propositional representation from either the belief or desire box as its only input, its output will be the same whichever box it used to supply the input. We need a bunch of additional assumptions in order to predict the similarity between believing and imagining Nichols cites: we need there to be a cognitive mechanism that takes as input sentences expressing propositions from the contents of either of these two boxes, but not from the desire box, and no other inputs, and generates as an output affective responses in the subject. This is a highly substantive assumption, for there are lots of additional ways one might generate affective responses from belief and imaginings. For instance, an 'introspective' mechanism might represent that a subject has such-and-such propositional attitudes, and this might be fed into a mechanism that converts sentences about beliefs and imaginings and desires into affective responses. The Single Code hypothesis by no means demands that such a mechanism treat imagination inputs and belief inputs alike, for this mechanism takes as inputs that a particular proposition be believed or imagined or desired; it keeps track of where the proposition came from, so to speak.
Nichols thinks that when I get angry because I believe an injustice has been committed, there's a particular mechanism -- call it MECH -- that takes contents of the belief box and imagination box as inputs and outputs anger upon being fed certain contents. And so MECH gives the same output when I imagine injustice. Here's an alternative hypothesis that looks no less antecedently plausible: I have a mechanism -- MECH-1 -- that takes belief-states as inputs, and spits out anger when fed the state of believing in injustice. And I have another mechanism, MECH-2, that acts on imaginings, MECH-3 that inputs desires, etc. The Single Code hypothesis doesn't do anything to favor one explanation here over another. Consequently, the Single Code hypothesis doesn't explain why imagining that p has many similar effects to believing that p.
(I also think, for exactly the same reason, that Nichols is wrong in this later paper to consider differences between belief and imagination to be in tension with the Single Code hypothesis, to which the latter need feel pressure to respond.)