fitparams madness
JCab wrote on Aug 02, 2006
I am new to optical astronomy so I have been learning to use the
digiphot package in IRAF and have been learning to hate it with a
passion. I have found many things don't work as advertised and
I am using the scisoft installation of IRAF on a Mac, so this is IRAF
version 2.12.2a-EXPORT. I have been following Massey and Davis's guide
to Stellar Photometry as well as Pullen's Zen of IRAF writeups and
discovering that there are all sorts of issues that make using IRAF
painful for this. So I ended up writing my own cl scripts to
automatically identify standards in the field (based on astrometric
headers in the FITS files and some calls to a perl script that accesses
WSClib), do the photometry (via daophot), and then collect the results.
A second call to a perl script then handles relabeling the phot file
produced by daophot with standards. Since I code not get mknobsfile to
work with my files (It kept spitting out errors about missing filters),
I made the obsfile with my perl code. I ran mkconfig, and after
examining the source mkconfig.cl file to see how it was mangling the
names of my input files, everything went swimmingly. Then I run
fitparams... The results make no sense at all.
The config file for my standards contains the following (I have trimmed
some of this for brevity):
===================================
catalog
V 5 # the V magnitude (INDEF = undefined)
BV 6 # the (B-V) color
UB 7 # the (U-B) color
VR 8 # the (V-R) color
error(V) 9 # the V magnitude errora (INDEF = undefined)
error(BV) 10 # the (B-V) color error
error(UB) 11 # the (U-B) color error
error(VR) 12 # the (V-R) color error
# Declare the observations file variables
observations
TU 3 # time of observation in filter U
XU 4 # airmass in filter U
xU 5 # x coordinate in filter U
yU 6 # y coordinate in filter U
mU 7 # instrumental magnitude in filter U
error(mU) 8 # magnitude error in filter U
TB 10 # time of observation in filter B
XB 11 # airmass in filter B
xB 12 # x coordinate in filter B
yB 13 # y coordinate in filter B
mB 14 # instrumental magnitude in filter B
error(mB) 15 # magnitude error in filter B
TV 17 # time of observation in filter V
XV 18 # airmass in filter V
xV 19 # x coordinate in filter V
yV 20 # y coordinate in filter V
mV 21 # instrumental magnitude in filter V
error(mV) 22 # magnitude error in filter V
# Sample transformation
transformation
fit b1=0.0, b2=0.35, b3=0.000
const b4=0.0
BFIT : mB = (BV + V) + b1 + b2 * XB + b3 * BV + b4 * BV * XB
===================================
When I run fitparams, it produces the following fit parameters:
parameter value error
b1 2.9949031 2.5226693 (fit)
b2 -5.8663588 1.9418215 (fit)
b3 -1.1653792 0.4006203 (fit)
And reports the first fit standard as
# objectid function fit residuals sigma
104_237 -6.036 -6.164918 0.1289186 2.69996
Now, for this standard, the catalog entry is
104_237 12:42:16.90 -00:51:18.0 15.395 1.088 0.918 0.647 0.000 0.000
and the observations I have for this standard are:
104_237 U 1:10:15.2 1.809 2116.471 152.284 -4.071 0.180
* B 1:15:28.8 1.721 2100.225 155.524 -6.036 0.049
* V 1:18:52.4 1.694 2094.486 161.607 -7.444 0.026
* R 1:21:30.5 1.673 2089.057 166.564 -7.973 0.018
So if I read everything correctly
V = 15.395 mU = -4.071 XU = 1.809
BV = 1.088 mB = -6.036 XB = 1.721
UB = 0.918 mV = -7.44 XV = 1.694
VR = 0.647 mR = -7.973 XR = 1.673
But based on this "fit", the functionally fit mB is:
Yet, fitparams is claiming the functional fit is -6.164918 !
Since Massey, Davis, and Pullen all seemed happy with the performance of
fitparams, I am assuming something is mucked up in a serious fashion here.
Is this a problem with the scisoft implementation of IRAF or am I
misunderstanding what the 'fit' value is.
Cheers,
JC
digiphot package in IRAF and have been learning to hate it with a
passion. I have found many things don't work as advertised and
I am using the scisoft installation of IRAF on a Mac, so this is IRAF
version 2.12.2a-EXPORT. I have been following Massey and Davis's guide
to Stellar Photometry as well as Pullen's Zen of IRAF writeups and
discovering that there are all sorts of issues that make using IRAF
painful for this. So I ended up writing my own cl scripts to
automatically identify standards in the field (based on astrometric
headers in the FITS files and some calls to a perl script that accesses
WSClib), do the photometry (via daophot), and then collect the results.
A second call to a perl script then handles relabeling the phot file
produced by daophot with standards. Since I code not get mknobsfile to
work with my files (It kept spitting out errors about missing filters),
I made the obsfile with my perl code. I ran mkconfig, and after
examining the source mkconfig.cl file to see how it was mangling the
names of my input files, everything went swimmingly. Then I run
fitparams... The results make no sense at all.
The config file for my standards contains the following (I have trimmed
some of this for brevity):
===================================
catalog
V 5 # the V magnitude (INDEF = undefined)
BV 6 # the (B-V) color
UB 7 # the (U-B) color
VR 8 # the (V-R) color
error(V) 9 # the V magnitude errora (INDEF = undefined)
error(BV) 10 # the (B-V) color error
error(UB) 11 # the (U-B) color error
error(VR) 12 # the (V-R) color error
# Declare the observations file variables
observations
TU 3 # time of observation in filter U
XU 4 # airmass in filter U
xU 5 # x coordinate in filter U
yU 6 # y coordinate in filter U
mU 7 # instrumental magnitude in filter U
error(mU) 8 # magnitude error in filter U
TB 10 # time of observation in filter B
XB 11 # airmass in filter B
xB 12 # x coordinate in filter B
yB 13 # y coordinate in filter B
mB 14 # instrumental magnitude in filter B
error(mB) 15 # magnitude error in filter B
TV 17 # time of observation in filter V
XV 18 # airmass in filter V
xV 19 # x coordinate in filter V
yV 20 # y coordinate in filter V
mV 21 # instrumental magnitude in filter V
error(mV) 22 # magnitude error in filter V
# Sample transformation
transformation
fit b1=0.0, b2=0.35, b3=0.000
const b4=0.0
BFIT : mB = (BV + V) + b1 + b2 * XB + b3 * BV + b4 * BV * XB
===================================
When I run fitparams, it produces the following fit parameters:
parameter value error
b1 2.9949031 2.5226693 (fit)
b2 -5.8663588 1.9418215 (fit)
b3 -1.1653792 0.4006203 (fit)
And reports the first fit standard as
# objectid function fit residuals sigma
104_237 -6.036 -6.164918 0.1289186 2.69996
Now, for this standard, the catalog entry is
104_237 12:42:16.90 -00:51:18.0 15.395 1.088 0.918 0.647 0.000 0.000
and the observations I have for this standard are:
104_237 U 1:10:15.2 1.809 2116.471 152.284 -4.071 0.180
* B 1:15:28.8 1.721 2100.225 155.524 -6.036 0.049
* V 1:18:52.4 1.694 2094.486 161.607 -7.444 0.026
* R 1:21:30.5 1.673 2089.057 166.564 -7.973 0.018
So if I read everything correctly
V = 15.395 mU = -4.071 XU = 1.809
BV = 1.088 mB = -6.036 XB = 1.721
UB = 0.918 mV = -7.44 XV = 1.694
VR = 0.647 mR = -7.973 XR = 1.673
But based on this "fit", the functionally fit mB is:
mB = (BV + V) + b1 + b2 * XB + b3 * BV
= (1.088 + 15.395) + 2.9949031 + -5.8663588*1.721 + -1.1653792*1.088
= 8.114
Yet, fitparams is claiming the functional fit is -6.164918 !
Since Massey, Davis, and Pullen all seemed happy with the performance of
fitparams, I am assuming something is mucked up in a serious fashion here.
Is this a problem with the scisoft implementation of IRAF or am I
misunderstanding what the 'fit' value is.
Cheers,
JC
JCab wrote on Aug 02, 2006
I just caught the typo in the config file that got generated (with my inputs). The observations and catalogs setup for the V filter is off in its column count by 1. Sigh.
Last post on Aug 02, 2006