As with so much from the classic series, the Valeyard has become an anomoly that has no legitimate explanation. In-universe, all we have to go on are two almost throw-away lines that describe his origins:
- The Master, in Trial of a Time Lord, gives the only on-screen information we have about his origin: "somewhere between your twelfth and final incarnation.".
- The Great Intelligence also mentions The Valeyard as one of the names that The Doctor will eventually be known as.
Unfortunately, both of those directly contradict the events of David Tennant and Matt Smith's tenures as the Doctor. By The Eleventh Doctor's own count, the Tenth Doctor was actually both the 11th and 12th incarnations, and he was supposed to be the "final" and was going to die. (Note that, on TV, the Master says "twelfth and final incarnation", but when the episode was turned into a novel, it was changed to "twelfth and thirteenth regenerations", which is even worse.) This means there is no opportunity for the Valeyard to come into being, if we interpret The Master's meaning in the most obvious way.
There are, however, a few alternative ways we can look at the Valeyard to try and force him to fit into canon:
- There's a popular theory that meta-crisis Tenth Doctor will become the Valeyard, which was explored in some supplemental materials (a comic book series, I think) but quickly rejected again. I don't see much support for this idea, since there's no indication that "Doctor" could get back to our universe, or that he could ever regenerate if he did.
- It's possible that the Valeyard was created off-screen at some point already, and we just didn't see it. Not very satisfying, but hard to argue against.
- It's possible that the Valeyard is yet to come, since Eleven is no longer the "final" incarnation. It's even possible that The Master was using The Doctor's own not-yet-created messed up numbering, and really meant "the Twelfth Doctor", despite being the 14th incarnation (13th if you count "distinct" incarnations).
Personally, I think The Valeyard is never going to happen, but that's based partly on information from the one of the audio productions, which is always sketchy canon-wise. In "Trial of the Valeyard" he explains that he was created by the "Thirteenth Doctor" as part of his attempts to get more regenerations illegally. After the events of "Time of the Doctor", there's no reason the Thirteenth Doctor (regardless if you consider that to be Matt Smith or the person that will follow Peter Capaldi) will need to try to bypass the regeneration limit, so there's no reason the Valeyard needs to occur.
In other words, there has been enough change in the Doctor's own future since "Trial of a Time Lord", including the Time War, rebooting the Universe, getting more regenerations, etc; that the Valeyard can likely be relegated to a remnant of an old, now-defunct timeline.
Out of Universe, the Valeyard is an absolute disaster, even for the famously canon-immune Doctor Who. For example, the New Adventures book series (the one with the Seventh Doctor in it) specifically forbade authors from mentioning anything about the Valeyard, calling it a "continuity nightmare".
Even the Doctor Who production team was pretty unhappy with the continuity mess created by The Valeyard. The original ending did, in fact, have The Doctor eventually become The Valeyard directly, and thus become a villain. The producers objects to this so strongly that the original script writer that created The Valeyard quit, and refused to let anyone use his script or and of its ideas in the show. So, if it seems like the Valeyard was a half-thought-out idea that was just kind of dropped on the floor -- that's exactly what happened, for legal reasons :)