A judge has ordered a sex offender to remain locked up while he is re-evaluated for risk to the public.