photon_ratio: Photo:photon ratio

Description Usage Arguments Value See Also Examples

View source: R/photon.ratio.R

Description

This function gives the photon ratio between two given wavebands of a radiation spectrum.

Usage

1
2
3
photon_ratio(w.length, s.irrad, w.band.num = NULL, w.band.denom = NULL,
  unit.in = "energy", check.spectrum = TRUE, use.cached.mult = FALSE,
  use.hinges = getOption("photobiology.use.hinges", default = NULL))

Arguments

w.length

numeric array of wavelength (nm)

s.irrad

numeric array of spectral (energy) irradiances (W m-2 nm-1)

w.band.num

waveband

w.band.denom

waveband

unit.in

character Allowed values "energy", and "photon", or its alias "quantum"

check.spectrum

logical Flag telling whether to sanity check input data, default is TRUE

use.cached.mult

logical Flag telling whether multiplier values should be cached between calls

use.hinges

logical Flag telling whether to use hinges to reduce interpolation errors

Value

a single numeric value giving the unitless ratio

See Also

Other photon and energy ratio functions: e_ratio, energy_ratio, eq_ratio, photons_energy_ratio, q_ratio, qe_ratio

Examples

1
2
3
4
5
6
7
# photon:photon ratio
with(sun.data,
     photon_ratio(w.length, s.e.irrad, new_waveband(400,500), new_waveband(400,700)))
# photon:photon ratio waveband : whole spectrum
with(sun.data, photon_ratio(w.length, s.e.irrad, new_waveband(400,500)))
# photon:photon ratio of whole spectrum should be equal to 1.0
with(sun.data, photon_ratio(w.length, s.e.irrad))

photobiology documentation built on Aug. 27, 2017, 5:05 p.m.