  We present a new approach, kernel regression, to determine photometric
redshifts for 399,929 galaxies in the Fifth Data Release of the Sloan Digital
Sky Survey (SDSS). In our case, kernel regression is a weighted average of
spectral redshifts of the neighbors for a query point, where higher weights are
associated with points that are closer to the query point. One important design
decision when using kernel regression is the choice of the bandwidth. We apply
10-fold cross-validation to choose the optimal bandwidth, which is obtained as
the cross-validation error approaches the minimum. The experiments show that
the optimal bandwidth is different for diverse input patterns, the least rms
error of photometric redshift estimation arrives at 0.019 using color+eClass as
the inputs, the less rms error amounts to 0.020 using ugriz+eClass as the
inputs. Here eClass is a galaxy spectra type. Then the little rms scatter is
0.021 with color+r as the inputs.
