Court says judges must avoid appearance of bias