Open a FITS file that contains a catalog of astronomical objects and dump some of its columns.
void FITS_tutorial7()
{
printf("\n\n--------------------------------\n");
printf("WELCOME TO FITS tutorial #7 !!!!\n");
printf("--------------------------------\n");
printf("We are going to open a table from a FITS file\n");
printf("and print out three columns for some of the objects.\n");
printf("This table contains a logical data type so this tutorial tests\n");
printf("that we can read it correctly\n\n");
if (hdu == 0) {
printf("ERROR: could not access the HDU\n");
return;
}
bp = (*vec4)[i];
gflux = (*vec3)[i];
ra = (*vec1)[i];
dec = (*vec2)[i];
if (bp) {
printf("RA %f DEC %f G-FLUX %f\n", ra, dec, gflux);
}
}
delete vec1;
delete vec2;
delete vec3;
delete vec4;
delete hdu;
}
- Author
- Elizabeth Buckley-Geer
Definition in file FITS_tutorial7.C.