
104 Cal.App.3d 92 (1980)
163 Cal. Rptr. 408
In re the Marriage of DEBORAH L. and JOE L. SCHWARTZ.
JOE L. SCHWARTZ, Appellant,
v.
DEBORAH L. SCHWARTZ, Respondent.
Docket No. 55232.
Court of Appeals of California, Second District, Division Five.
April 1, 1980.
*93 COUNSEL
Samuel Frizell and John C. Nelson for Appellant.
Pryor & Benson and Roger J. Pryor for Respondent.
OPINION
KAUS, P.J.
Petitioner Joe L. Schwartz appeals from an order of the superior court modifying a joint custody agreement entered into between himself and his former wife, Deborah L. Schwartz.
Deborah and Joe were married in October 1964. Their union produced two children  a boy, Shannon, and a girl, Sonja. Thirteen years later, in 1977, the court granted Joe an interlocutory judgment of dissolution, which, among other things, provided that custody of the children be awarded jointly to Joe and Deborah. It further declared that "[t]he children shall spend the remainder of the school year 1976-1977 and the school year of 1977-1978 residing with [Deborah]. The parent with *94 whom the children are not residing at any given time shall have visitation rights for all weekends and school holidays. Children shall not reside with [Joe] for school year unless he has a live-in housekeeper or a spouse. Children shall continue to reside with [Deborah] for school year periods unless they request to reside with [Joe] and [Joe] has the aforementioned housekeeper or spouse. Each party agrees to take the children to reside with him/her if the other parent remarries and is unwilling/unable to have children reside with him/her."
During the summer of 1978, both the children resided with Joe, in California, as per the custody agreement. When vacation came to a close, Sonja chose to return to her mother in Texas, while Shannon expressed a desire to remain in his father's household. The children's wishes were respected; Shannon was enrolled in school in California while Sonja returned to her mother in Texas.
On November 13, 1978, well after the children were into the school year, Deborah filed an order to show cause re: modification, by which she sought termination of the joint custody arrangement and a concomitant award of sole custody in her favor. In response, Joe sought a ruling permitting his son  then age 10  to reside with him during the school year. The actions were heard on December 11, 1978; the court ordered modification in accordance with Deborah's wishes. This appeal ensued.
At trial, Joe introduced evidence of and testified to the fact that he had remarried and that he desired Shannon to reside with him during the school year. He also produced an affidavit setting forth Shannon's desire to remain under his custody and control. Deborah, on the other hand, sought to prove that, though single, she too held out an adequate home for the children; she sought physical custody of both children despite Shannon's wishes to remain with his father.
From the outset of the hearing, the court made it clear that it had no great respect for the parties' initial custody agreement. For instance, while reviewing the facts, the court commented: "I gather you [counsel] are gleaning my attitude toward this custody order [w]ithout my articulating my contempt for its creation." It further declared that in its view, the parties were "letting the children dictate things that they are not supposed to dictate." Accordingly, it announced that "[t]he children will be put together as the end result of this hearing." It then inquired of both parties as to whether they were "prepared to proceed on that basis?" and received their affirmative replies.
*95 Thereafter, the court took testimony from the parties, but refused to speak with Shannon despite Joe's request that he do so. The court opined that, "[e]ven if he were to tell me, `I want to stay with Daddy,' I think it is still best for him to stay with his sister, not the mother, the sister. I think splitting up these siblings is a terrible thing to do. That is going to be my order, so I may well be procedurally in error all the way up and down the line, but my concern is only with the children, so I'm going to make that order.... I'm again glad at my own feelings. Not the mother, I'm glad he is going back to his sister.... That is how I feel."
Finally, the court summarized its ruling by stating: "I reiterate so there is no doubt in anybody's mind, I have nothing against the adults. I'm concerned about the child and my experience has been that it is adverse to their best interests to be split. That is all."
(1) Not surprisingly, Joe asserts that the court prejudicially abused its discretion by making its ruling on the basis of preexisting bias, rather than on the evidence adduced.[1] We heartily agree.
Manifestly, the court harbored and exhibited an unshakeable prejudice against the parties' court-approved custody agreement and the possibility that the children might properly reside in different homes. While it may be that under most circumstances most courts would probably conclude on the basis of the evidence that splitting custody of the children would be detrimental to their best interests, this particular court obviously did not propose to engage in any such reasoned judgment.
This was, of course, clear error. Joe was entitled to an order based on the court's review of all the evidence before it, as well as on the exercise of an impartial legal discretion. The fixed views held by the court here made the hearing a mere formality  a foregone conclusion. (See, for example, Adoption of Richardson (1967) 251 Cal. App.2d 222 [59 Cal. Rptr. 323].)
*96 Deborah insists that the parties shared the court's prejudice and that Joe is therefore in no position to complain. What happened was that the court, which had already expressed its contempt for the judgment, leaned on the parties themselves to agree that splitting the children was "the worst thing you can do" and later got the attorneys to concur that the hearing would be conducted on the basis that "[t]he children will be put together as the end result of this hearing."
We disagree that these agreements, clearly the result of judicial arm-twisting, neutralized the prejudicial effect of the court's bias. Nevertheless, even if they did, the hearing which ensued was conducted under ground rules which differed 180 degrees from what they should have been: Somehow the court had persuaded itself that Joe, rather than Deborah was the moving party[2] and that under In re Marriage of Mehlmauer (1976) 60 Cal. App.3d 104 [131 Cal. Rptr. 325] it was his burden to show "why custody should change." Since it was crystal clear that the moving party was Deborah, the error with respect to the burden of proof is, itself, sufficient to mandate a reversal. (Henderson v. Harnischfeger Corp. (1974) 12 Cal.3d 663, 670-673 [117 Cal. Rptr. 1, 527 P.2d 353].)
Reversed.
Ashby, J., and Hastings, J., concurred.
NOTES
[1]  He also assigns prejudicial error to the court's adamant refusal to speak with Shannon, noting both that the parties' agreement clearly contemplated such action, and that Civil Code section 4600 provides that "[i]f a child is of sufficient age and capacity to reason so as to form an intelligent preference as to custody, the court shall consider and give due weight to the wishes of the child in making an award of custody or modification thereof...." In light of our conclusion above, however, we need not, and thus do not decide the merits of this contention.
[2]  The process of reasoning by which the court reached this conclusion was, itself, the result of its basic prejudice against divided custody. Although Joe had not asked for custody of both children, the court, quite irrelevantly, got him to say that the only reason he had not asked for such custody was that he did not think the court would grant it. The court then said: "Be disabused of that.... You want both children?" Joe replied: "Yes, sir." In this fashion Deborah's request for a modification of the judgment was transformed into one by Joe.
