Awhile back, I posted on one such internal factor, the relative weight of autonomy and precedent in the decision making process. Although this is an important factor in any judicial system (as can be seen here), in Halacha the question is more complicated since we have the added component of the quasi-canonic status of the texts. This must compete with the posek's own self-perception as an "agent of God" who is empowered to make orginal decisions.
In studying this issue, it is important to differentiate between those parts of Orach Chaim which carry the extra factor of Minhag making precedent much more powerful and Choshen Mishpat issues which as a judicial system has somewhat different rules then the rest of Shulchan Aruch.
In studying this (and any other meta-halachic question), it is important to cite support both from programmatic statements of posekim and from analysis of actual responsa or codes.
An excellent demonstration of the necessity for such double support can be found in footnote 28 here which shows that although in his programmatic statements, the Maharshal insists on absolute autonomy, analysis of his responsa shows a healthy respect for precedent as well.
Background - stages of codification
1 - The Talmud - The debate here centers around the cryptic statement in "Sifra D' Adam haRishon" - רבינא ור' אשי סופר הוראה. This has traditionally been interpreted as referring to the redaction of the Talmud. But according to Tosafos in A"Z (beginning of Ch. 2) this refers to Pesak. In an (un-scientific) experiment here, I showed that the later Saboraim did argue with R' Ashi and Ravina so that it would seem that one should not attribute to much weight to this statement (as Halivni suggests see Mekorot U' Masoret - Bava Basra - Introduction. I mentioned this point to him when I met him and he agreed but unfortunately I didn't take down his exact comment.)
2. Geonim - See the sources in cited in Encyclopedia Talmudit - S.V. Halacha - last section. Note that the Rambam has no qualms of arguing with the Geonim. Since as I mentioned in the previous note the Geonim who authored the והלכתא statements and these argue on the Amoraim, by way of as syllogism of sorts the Rambam should technically be able to argue on the Amoraim!!!
3. Rambam - See Yitzchok Zev Kahana - הפולמוס מסביב קביעת ההכרעה כהרמב"ם סיני, לו-לח
4. Shulchan Aruch - The מאסף לכל המחנות here (as in everywhere else) is Chacham Ovadiah in the various Pesichos and Hakdamos to his Yabia Omer - See esp. Pesicha to Vol. 5 and sources cited there
 Even here external factors can also be involved. Thus, in two seperate studies on the role of precedent in Halacha, the Orthodox writer (Jeffrey Woolf) insists that the judge retains significant judicial discretion whereas the Reform writer says that they do not. This is because of the system itself has a mechanism for change then there would be no need for a large scale Reform. [Taken from Larry Rabinovich, The Judge as Educator, JLA, 04 - Note 52. My thanks to Mr. Rabinovich for making his article available to me.]