  We propose two types of universal codes that are suited to two asymptotic
regimes when the output alphabet is possibly continuous. The first class has
the property that the error probability decays exponentially fast and we
identify an explicit lower bound on the error exponent. The other class attains
the epsilon-capacity the channel and we also identify the second-order term in
the asymptotic expansion. The proposed encoder is essentially based on the
packing lemma of the method of types. For the decoder, we first derive a
R\'enyi-relative-entropy version of Clarke and Barron's formula the distance
between the true distribution and the Bayesian mixture, which is of independent
interest. The universal decoder is stated in terms of this formula and
quantities used in the information spectrum method. The methods contained
herein allow us to analyze universal codes for channels with continuous and
discrete output alphabets in a unified manner, and to analyze their
performances in terms of the exponential decay of the error probability and the
second-order coding rate.
