Learn R Programming

ProFound (version 1.14.1)

profoundGainConvert: Convert gain between mag-zero points

Description

Simple function to update the gain (electrons/ADU) when changing between magnitude zero points. These gains are what should be passed to e.g. profoundMakeSigma.

Usage

profoundGainConvert(gain = 1, magzero = 0, magzero_new = 0)

Arguments

gain

Numeric scalar or vector; the current gain/s in electrons/ADU.

magzero

Numeric scalar or vector; the current magnitude zero point/s.

magzero_new

Numeric scalar or vector; the new magnitude zero point/s.

Value

Numeric scalar or vector; the new gain/s.

Details

A simple function that is mostly here to avoid silly conversion mistakes. The conversion is calculated as: gain*10^(-0.4*(magzero_new - magzero)), where an object magnitude can be calculated from ADU flux as -2.5*log10(flux_ADU)+magzero.

See Also

profoundMakeSigma, profoundFlux2Mag, profoundMag2Flux

Examples

Run this code
# NOT RUN {
#For optical survey data typically images with gain~1 have a magzero~30:
profoundGainConvert(1,30,0)
# }

Run the code above in your browser using DataLab