Chris Beaumont's IDL Library

Download source code

single page | use frames     summary     class     fields     routine details     file attributes




result = nicer(mag, dmag [, color=color] [, covar=covar] [, ks=ks])

This function estimates the amount of reddening a star is seen through, based on its observed colors.

Algorithm taken from Lombardi and Alves 2001. Equation references in code refer to that paper. JHK extinction law taken from Lebofsky 1985 IRAC extinction law taken from Indebetouw, Mathis et al. 2005


mag in required

An NBAND by NOBJECT array, or an NBAND vector. Each row of the array represents an object, and the columns in that array list the magnitudes of that object in NBAND different photometric bands. If NBAND = 3, the colors are assumed to be (J,H,Ks). If NBAND = 5, the colors are assumed to be (J,H,Ks,I1,I2). In general, any set of magnitudes is allowed, as long as the appropriate keyword variables are passed (see below).

dmag in required

The uncertainty on each magnitude measurement.


color in optional

A vector of the mean color of (unreddened) stars. An NBAND-1 vector. Each entry refers to the mean color formed by taking mag_i - mag_i+1. For example, if NBAND = 3, the assumed magnitudes are JHK, and the colors are J-H and H-K. Default values are provided for (JHK) and (JHK I1 I2) if NBAND = 3 or 5. Otherwise, this vector must be provided.

covar in optional

An NBAND-1 by NBAND-1 matrix, specifying the covariance of colors of unreddened stars. This is provided for (JHK) and (JHK I1 I2) if NBAND = 3 or 5. Otherwise, this matrix must be provided.

ks in optional

The reddening vector for each color. That is, c_i(observed) = c_i(true) + Av * k. This is provided for (JHK) and (JHK I1 I2) when NBAND = 3 or 5. Otherwise, this vector must be provided.

Author information


Written by: Chris Beaumont July 2008 November 2008: cnb. Updated to incorporate IRAC bands 1 and 2 November 2009: cnb. Completely re-written to better generalize to different photometric bands. Calling sequence changed.

File attributes

Modifcation date: Thu Dec 9 21:19:47 2010
Lines: 158