PyDL:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- pydl v1.0.0-rc2 »
- SDSS Spectroscopic Data (`pydl.pydlspec2d`) »
- preprocess_spectra

# preprocess_spectra

pydl.pydlspec2d.spec1d.preprocess_spectra(flux, ivar, loglam=None, zfit=None, aesthetics='mean', newloglam=None, wavemin=None, wavemax=None, verbose=False)

  Handle the processing of input spectra through the `combine1fiber()` stage.

  Parameters
    flux array-like

      The input spectral flux.

    ivar array-like

      The inverse variance of the spectral flux.

    loglam array-like, optional

      The input wavelength solution.

    zfit array-like, optional

      The redshift of each input spectrum.

    aesthetics `str`, optional

      This parameter will be passed to `combine1fiber()`.

    newloglam array-like, optional

      The output wavelength solution.

    wavemin `float`, optional

      Minimum wavelength if `newloglam` is not specified.

    wavemax `float`, optional

      Maximum wavelength if `newloglam` is not specified.

    verbose `bool`, optional

      If `True`, print extra information.

  Returns
    `tuple` of `numpy.ndarray`

      The resampled flux, inverse variance and wavelength solution, respectively.