Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/profoundProFound.R

This is the highest level source detection function provided in `ProFit`

, calculating both the initial segmentation map and reasonable estimates for the total flux apertures for each source in an automatic manner.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ```
profoundProFound(image = NULL, segim = NULL, objects = NULL, mask = NULL, skycut = 1,
pixcut = 3, tolerance = 4, ext = 2, reltol = 0, cliptol = Inf, sigma = 1, smooth = TRUE,
SBlim, SBdilate = NULL, SBN100 = 100, size = 5, shape = "disc", iters = 6,
threshold = 1.05, magzero = 0, gain = NULL, pixscale = 1, sky = NULL, skyRMS = NULL,
redosegim = FALSE, redosky = TRUE, redoskysize = 21, box = c(100,100), grid = box,
skygrid_type = 'new', type = "bicubic", skytype = "median", skyRMStype = "quanlo",
roughpedestal = FALSE, sigmasel = 1, skypixmin = prod(box)/2, boxadd = box/2,
boxiters = 0, conviters = 100, iterskyloc = TRUE, deblend = FALSE, df = 3, radtrunc = 2,
iterative = FALSE, doclip = TRUE, shiftloc = FALSE, paddim = TRUE, header,
verbose = FALSE, plot = FALSE, stats = TRUE, rotstats = FALSE, boundstats = FALSE,
nearstats = boundstats, groupstats = boundstats, group = NULL, groupby = 'segim_orig',
offset = 1, haralickstats = FALSE, sortcol = "segID", decreasing = FALSE,
lowmemory = FALSE, keepim = TRUE, watershed = 'ProFound', pixelcov = FALSE,
deblendtype = 'fit', psf = NULL, fluxweight = 'sum', convtype = 'brute',
convmode = 'extended', fluxtype = 'Raw', app_diam = 1, Ndeblendlim = Inf, ...)
``` |

`image` |
Numeric matrix; required, the image we want to analyse. If image is a list as created by |

`segim` |
Integer matrix; a specified segmentation map of the image. This matrix *must* be the same dimensions as image if supplied. If this option is used then |

`objects` |
Boolean matrix (1,0); optional, object mask where 1 is object and 0 is sky. If provided, this matrix *must* be the same dimensions as image. If provided then this is used to initially mask pixels for determining the correct sky when sky=NULL. |

`mask` |
Boolean matrix or integer scalar (1,0); optional, parts of the image to mask out (i.e. ignore). If a matrix is provided, this matrix *must* be the same dimensions as image where 1 means mask out and 0 means use for analysis. if a scalar is provided it indicates the exact image values that should be treated as masked (e.g. by setting masked pixels to 0 or -999). The latter achieves the same effect as setting masked image pixels to NA, but allows for the fact not all programs can produce |

`skycut` |
Numeric scalar; the lowest threshold to make on the image in units of the skyRMS. Passed to |

`pixcut` |
Integer scalar; the number of pixels required to identify an object. Passed to |

`tolerance` |
Numeric scalar; the minimum height of the object in the units of skyRMS between its highest point (seed) and the point where it contacts another object (checked for every contact pixel). If the height is smaller than the tolerance, the object will be combined with one of its neighbours, which is the highest. The range 1-5 offers decent results usually. Passed to |

`ext` |
Numeric scalar; radius of the neighbourhood in pixels for the detection of neighbouring objects. Higher value smooths out small objects. Passed to |

`reltol` |
Numeric scalar; only relevant for watershed='ProFound'. A modifier to the tolerance, modifying it by the ratio of the segment peak flux divided by the saddle point flux to the power reltol. The default means the reltol has no effect since this modifier becomes 1. A larger value of reltol means segments are more aggressively merged together. Can be (and often should be in practice) negative. The effect of using reltol and setting to negative is that the central brighter parts of galaxies are kept together in a single segment, and deblending is more common on the outskirts (where it should have less effect on the overall flux). The principle is that we need to be very confident a bright source needs to be split near its peak flux, but can be more aggressive in the outskirts. |

`cliptol` |
Numeric scalar; only relevant for watershed='ProFound'. If (image-sky)/skyRMS is above this level where segments touch then they are always merged, regardless of other criteria. When thinking in terms of sky RMS, values between 20-100 are probably appropriate for merging very bright parts of stars back together in optical data. |

`sigma` |
Numeric scalar; standard deviation of the blur used when smooth=TRUE. Passed to |

`smooth` |
Logical; should smoothing be done on the target image? Passed to |

`SBlim` |
Numeric scalar; the mag/asec^2 surface brightness threshold to apply. This is always used in conjunction with skycut, so set skycut to be very large (e.g. Inf) if you want a pure surface brightness threshold for the segmentation. magzero and pixscale must also be present for this to be used. If a matrix is provided, this matrix *must* be the same dimensions as image. Passed to |

`SBdilate` |
Numeric scalar; how many surface brightness mags beyond the sky RMS to push the dilation process. Default is NULL, meaning this is not triggered. The extra dilation logic is that if the new mean surface brightness in the dilated annulus is above the sky surface brightness + SBdilate and we are adding more than SBN100 pixels then we will continue to dilate. This works well to capture extra flux in very large extended structures, where the fractional flux might not be changing much, but where we can safely keep dilating. Sensible values are between 0-2 (i.e. with 100 pixels we might be able to reliably push 2 mags fainter than the nominal sky surface brightness). |

`SBN100` |
Integer scalar; the number of new annulus pixels in our dilated segment required to trigger the SBdilate criteria. |

`size` |
Integer scalar; the size (e.g. width/diameter) of the dilation kernel in pixels. Should be an odd number else will be rounded up to the nearest odd number. See |

`shape` |
Character scalar; the shape of the dilation kernel. See |

`iters` |
Integer scalar; the maximum number of curve of growth dilations that should be made. This needs to be large enough to capture all the flux for sources of interest, but increasing this will increase the computation time for |

`threshold` |
Numeric scalar; After the curve of growth dilations, threshold is the relative change of the converging property (see converge) that flags convergence. If consecutive iterations have a relative difference within this ratio then the dilation is stopped, and this iteration is used to define the segmentation of the object. The effect of this is that different objects will be dilated for a different number of iterations. Usually fainter sources require more. Note from v1.4: covergence has to be monotonically decreasing as dilation occurs, i.e. the flux can grow from x1.4 to x1.1 (next iteration), but not x1.4 to x2. Dilations with increasing growth rate are ignored. |

`magzero` |
Numeric scalar; the magnitude zero point. What this implies depends on the magnitude system being used (e.g. AB or Vega). If provided along with pixscale then the flux and surface brightness outputs will represent magnitudes and mag/asec^2. |

`gain` |
Numeric scalar; the gain (in photo-electrons per ADU). This is only used to compute object shot-noise component of the flux error (else this is set to 0). |

`pixscale` |
Numeric scalar; the pixel scale, where pixscale=asec/pix (e.g. 0.4 for SDSS). If set to 1 (default), then the output is in terms of pixels, otherwise it is in arcseconds. If provided along with magzero then the flux and surface brightness outputs will represent magnitudes and mag/asec^2. |

`sky` |
User provided estimate of the absolute sky level. If this is not provided then it will be computed internally using |

`skyRMS` |
User provided estimate of the RMS of the sky. If this is not provided then it will be computed internally using |

`redosegim` |
Logical; should the segmentation map be modified based using the interim "better sky"? This means pixels falling below the new skycut would be excluded from the final segmentation map. This is usually only required if the sky subtraction was radically poor and complex in the first place. Will be forced to FALSE if the user supplies a segmentation map. If the user wants to flag object pixels they should pass it to objects. |

`redosky` |
Logical; should the sky and sky RMS grids be re-computed using the final segmentation map? This uses |

`redoskysize` |
Integer scalar; the size (e.g. width/diameter) of the dilation kernel in pixels to apply to the object mask before performing the initial and final aggressively masked sky estimates (the latter is only relevant if redosky=TRUE). Should be an odd number else will be rounded up to the nearest odd number. See |

`box` |
Integer vector; the dimensions of the box car filter to estimate the sky with. For convenience, if length 1 then both dimensions of box used internally are assumed to equal the specified box. I.e. 200 would be interpreted as c(200,200). Dependent default arguments (grid, boxadd and skypixmin) are updated sensibly. |

`grid` |
Integer vector; the resolution of the background grid to estimate the sky with. By default this is set to be the same as the box. |

`skygrid_type` |
Character scalar; either 'new' (the new ADACS C++ sky grid code) or 'old' (the older R based code as used for ProFound <= v1.10). |

`type` |
Character scalar; either "bilinear" for bilinear interpolation or "bicubic" for bicubic interpolation. The former creates sharper edges, the later is guaranteed to be first order differentiable. As of |

`skytype` |
Character scalar; the type of sky level estimator used. Allowed options are 'median' (the default), 'mean', 'mode' and 'converge' (see |

`skyRMStype` |
Character scalar; the type of sky level estimator used. Allowed options are 'quanlo' (the default), 'quanhi', 'quanboth', 'sd' and 'converge' (see |

`roughpedestal` |
Logical; when the initial "rough sky" is computed, should only a pedestal (based on the median of the sky map) be used for the sky? This is a good option if the image is known to contain a *very* large (many times the box size) galaxy that might otherwise be over subtracted by the initial rough sky map. |

`sigmasel` |
Numeric scalar; the quantile to use when trying to estimate the true standard-deviation of the sky distribution. If contamination is low then the default of 1 is about optimal in terms of S/N, but you might need to make the value lower when contamination is very high. |

`skypixmin` |
Numeric scalar; the minimum number of sky pixels desired in our cutout. The default is that we need half the original number of pixels in the box to be sky. |

`boxadd` |
Integer vector; the dimensions to add to the box to capture more pixels if skypixmin has not been achieved. By default this is set to be the same as the box/2. |

`boxiters` |
Integer scalar; the number of box+boxadd iterations to attempt in order to capture skypixmin sky pixels. The default means the box will not be grown at all. |

`conviters` |
Integer scalar; number of iterative sky convergence steps when skytype = 'converge' and/or skyRMStype = 'converge'. |

`iterskyloc` |
Logical; should the last segment dilation be used to estimate a local sky value? If this is TRUE then this estimate is used to determine flux convergence for the dilations. It will also be used to return the additional skyseg_mean column in the segstats output provided. If TRUE then one additional dilation is made compared to the specified iters. |

`deblend` |
Logical; should segment flux be deblended using |

`df` |
Integer scalar; degrees of freedom for the non-parametric spline fitting. Only relevant if deblend=TRUE, see |

`radtrunc` |
Numeric scalar; the maximum allowed radius beyond the edge-most segment pixel to consider when deblending. Keeping this low (1-3) ensures segments do not gather flux from very distant regions of the group. Only relevant if deblend=TRUE, see |

`iterative` |
Logical; should each segment profile fit be subtracted as it goes along? TRUE tends to remove the pedestal from a large galaxy that has faint objects embedded on top. Only relevant if deblend=TRUE, see |

`doclip` |
Logical; should the unmasked non-object pixels used to estimate to local sky value be further sigma-clipped using |

`shiftloc` |
Logical; should the cutout centre for the sky shift from loc of the desired box size extends beyond the edge of the image? (See |

`paddim` |
Logical; should the cutout be padded with image data until it meets the desired box size (if shiftloc is true) or padded with NAs for data outside the image boundary otherwise? (See |

`header` |
Full FITS header in table or vector format. If this is provided then the segmentations statistics table will gain RAcen and Decen coordinate outputs. Legal table format headers are provided by the |

`verbose` |
Logical; should verbose output be displayed to the user? Since a big image can take a long time to run, you might want to monitor progress. |

`plot` |
Logical; should a diagnostic plot be generated? This is useful when you only have a small number of sources (roughly a few hundred). With more than this it can start to take a long time to make the plot! |

`stats` |
Logical; should statistics on the segmented objects be returned using |

`rotstats` |
Logical; if TRUE then the asymm, flux_reflect and mag_reflect are computed, else they are set to NA. This is because they are very expensive to compute compared to other photometric properties. |

`boundstats` |
Logical; if TRUE then various pixel boundary statistics are computed (Nedge, Nsky, Nobject, Nborder, edge_frac, edge_excess and FlagBorder). If FALSE these return NA instead (saving computation time). Note by construction Nedge = Nobject + Nsky + Nborder. If you want to adjust specifically for Nmask then Nsky = Nsky - Nmask. |

`nearstats` |
Logical; if TRUE then the IDs of nearby segments is calculated via |

`groupstats` |
Logical; if TRUE then the IDs of grouped dilated segments (based on the output segim) is calculated via |

`group` |
List; you can pass in the output from |

`groupby` |
Character scalar; How should the grouped segmentation map be formed that will be used to produce the groupstats output? Options are either via 'segim' or 'segim_orig'. 'segim' will create more groups, 'segim_orig' will have less. |

`offset` |
Integer scalar; the distance to offset when searching for nearby segments (used in both |

`haralickstats` |
Logical; if TRUE then the Haralick texture statistics are computed using the |

`sortcol` |
Character scalar; name of the output column that the returned segmentation statistics data.frame should be sorted by (the default is segID, i.e. segment order). See below for column names and contents. |

`decreasing` |
Logical; if FALSE (default) the segmentation statistics data.frame will be sorted in increasing order, if TRUE the data.frame will be sorted in decreasing order. |

`lowmemory` |
Logical; if TRUE then a low memory mode of ProFound will be used. This limits the large image pixel matched outputs to just segim, with segim_orig, objects and objects_redo set to NULL, and sky and skyRMS set to 0. Internally the sky and skyRMS are used as normal for flux estimates, but they are removed as soon as possible within the function in order to free up memory. |

`keepim` |
Logical; if TRUE then the input image and mask matrices are passed through to the image output of the function. If FALSE then this is set to NULL. |

`watershed` |
Character scalar; the funciton to use to achieve the watershed deblend. Allowed options are 'EBImage' for EBImage::watershed, and 'ProFound' for the new |

`pixelcov` |
Logical, should pixel covariance be considered when computing errors? TRUE uses |

`deblendtype` |
Character scalar, either 'fit' (default, where the segments in the image are approximately fitted for deblending) or 'psf' (where a PSF must be provided to argument psf). Only relevant if deblend=TRUE, see |

`psf` |
Numeric matrix; must be provided if deblendtype='psf'. Only relevant if deblend=TRUE, see |

`fluxweight` |
Numeric scalar; only relevent when deblendtype='psf'. Either 'sum' (where the sum of the current segment weights the deblend solution), 'peak' (where only the peak pixel flux in the segment it used) or 'none' (no additional weighting is used). Only relevant if deblend=TRUE, see |

`convtype` |
Character scalar, only relevent when deblendtype='psf'. Specifies the type on convolver to use. Available options are displayed by running |

`convmode` |
Character scalar, only relevent when deblendtype='psf'. Either 'extended' (the whole segment is convolved with the target PSF when determining the deblend) or 'psf' (the provided PSF is centred at the peak flux for deblending). Only relevent when deblendtype='psf'. The former makes more sense for well resolved images (say optical) where the main issue in the deblending is the overlapping of resolved flux components. The latter works better in the regime where the image is barely resolved beyond the PSF, and this dominates the uncertainty of the deblend. |

`fluxtype` |
Character scaler; specifies whether fluxes will be output in Jansky / MicroJansky ('Jansky' / 'microjansky'), or in raw/unscaled image ADUs ('Raw' / 'ADU' / 'ADUs', the default). You can only use Jansky / MicroJansky if the specified magzero gets the data into the AB system, else the fluxes will not be Jansky. |

`app_diam` |
Numeric scalar; the diameter in arc seconds to use for pseudo aperture photometry. This will use the appropriate pixel scale to convert the aperture into image units. The psuedo aperture photometry is output to columns flux_app and mag_app in segstats. |

`Ndeblendlim` |
Integer scalar; the limit for the number of pixels to consider in a deblending complex (Ngroup [number of segments in the group] x Npix [number of pixels in the group]). You might want to set this to a value similar to allowable machine memory (1e8 - 1e9 often) just to avoid extreme cases (e.g. large stars with lots of pixels and lots of segments). Only relevant if deblend=TRUE, see |

`...` |
Further arguments to be passed to |

This high level function is both a source detection and a segmented aperture growing function. The latter is achieved through consecutive dilation and flux measurement operations. It is not super fast, but it is designed to be fairly robust and fast enough for most use cases.

`profoundProFound`

initially makes a segmentation map using the `profoundMakeSegim`

function. It then makes repeated dilations and flux measurements of this segmentation map using `profoundMakeSegimDilate`

, and calculates the convergent flux segment for each source. These are combined to make a final segmentation map with associated source statistics (if requested).

The defaults should work reasonably well on modern survey data (see Examples), but should the solution not be ideal try modifying these parameters (in order of impact priority): skycut, pixcut, tolerance, sigma, ext.

`profoundMakeSegimDilate`

is similar in nature to the pixel growing `objmask`

routine in `IRAF`

(see the ngrow and agrow description at http://iraf.noao.edu/projects/ccdmosaic/objmasks/objmasks.html). This similarity was discovered after implementation, but it is worth noting that the higher level curve of growth function `profoundProFound`

is not trivially replicated by other astronomy tools.

An object list of class 'profound' containing:

`segim` |
Integer matrix; the dilated and converged segmentation map matched pixel by pixel to image. |

`segim_orig` |
Integer matrix; the pre-dilated segmentation map matched pixel by pixel to image. |

`objects` |
Logical matrix; the object map matched pixel by pixel to image. 1 means there is an object at this pixel, 0 means it is a sky pixel. Can be used as a mask in various other functions that require objects to be masked out. |

`objects_redo` |
Logical matrix; the dilated object map matched pixel by pixel to image. See redosky and redoskysize. Can be used as a mask in various other functions that require objects to be masked out. |

`sky` |
The estimated sky level of the image. |

`skyRMS` |
The estimated sky RMS of the image. |

`image` |
The input image matrix if keepim=TRUE, else NULL. |

`mask` |
The input or computed mask matrix if keepim=TRUE, else NULL. |

`segstats` |
If stats=TRUE then contains the output of |

`Nseg` |
The total number of segments extracted (dim(segstats)[1]). |

`near` |
If nearstats=TRUE then contains the output of |

`group` |
If groupstats=TRUE then contains the output of |

`groupstats` |
If groupstats=TRUE and stats=TRUE then contains the output of |

`header` |
The header provided, if missing this is NULL. |

`SBlim` |
The surface brightness limit of detected objects. Requires at least magzero to be provided and skycut>0, else NULL. |

`magzero` |
The assumed magnitude zero point. This is relevant to various outputs returned by the segmentation statistics. |

`dim` |
The dimensions of the processed image. |

`pixscale` |
The assumed pixel scale. This is relevant to various outputs returned by the segmentation statistics. |

`gain` |
The assumed image gain (if NULL it was not used). This is relevant to various outputs returned by the segmentation statistics. |

`imarea` |
The area of the provided image in degrees squared. |

`skyLL` |
The log-likelihood of negative sky pixel Chi-Sq distribution (the larger the better the sky estimation). |

`call` |
The original function call. |

`date` |
The date, more specifically the output of |

`time` |
The elapsed run time in seconds. |

`ProFound.version` |
The version of |

`R.version` |
The version of |

If stats=TRUE then the function `profoundSegimStats`

is called and the segstats part of the returned list will contain a data.frame with columns (else NULL):

`segID` |
Segmentation ID, which can be matched against values in segim |

`uniqueID` |
Unique ID, which is fairly static and based on the xmax and ymax position |

`xcen` |
Flux weighted x centre |

`ycen` |
Flux weighted y centre |

`xmax` |
x position of maximum flux |

`ymax` |
y position of maximum flux |

`RAcen` |
Flux weighted degrees Right Ascension centre (only present if a header is provided) |

`Deccen` |
Flux weighted degrees Declination centre (only present if a header is provided) |

`RAmax` |
Right Ascension of maximum flux (only present if a header is provided) |

`Decmax` |
Declination of maximum flux (only present if a header is provided) |

`sep` |
Radial offset between the cen and max definition of the centre (units of pixscale, so if pixscale represents the standard asec/pix this will be asec) |

`flux` |
Total flux (calculated using image-sky) in ADUs or Jansky |

`mag` |
Total flux converted to mag using magzero |

`flux_app` |
Pseudo aperture (as specified by app_rad) flux (calculated using image-sky) in ADUs or Jansky |

`mag_app` |
Pseudo aperture (as specified by app_rad) flux converted to mag using magzero |

`cenfrac` |
Fraction of flux in the brightest pixel |

`N50` |
Number of brightest pixels containing 50% of the flux |

`N90` |
Number of brightest pixels containing 90% of the flux |

`N100` |
Total number of pixels in this segment, i.e. contains 100% of the flux |

`R50` |
Approximate elliptical semi-major axis containing 50% of the flux (units of pixscale, so if pixscale represents the standard asec/pix this will be asec) |

`R90` |
Approximate elliptical semi-major axis containing 90% of the flux (units of pixscale, so if pixscale represents the standard asec/pix this will be asec) |

`R100` |
Approximate elliptical semi-major axis containing 100% of the flux (units of pixscale, so if pixscale represents the standard asec/pix this will be asec) |

`SB_N50` |
Mean surface brightness containing brightest 50% of the flux, calculated as flux*0.5/N50 (if pixscale has been set correctly then this column will represent mag/asec^2. Otherwise it will be mag/pix^2) |

`SB_N90` |
Mean surface brightness containing brightest 90% of the flux, calculated as flux*0.9/N90 (if pixscale has been set correctly then this column will represent mag/asec^2. Otherwise it will be mag/pix^2) |

`SB_N100` |
Mean surface brightness containing all of the flux, calculated as flux/N100 (if pixscale has been set correctly then this column will represent mag/asec^2. Otherwise it will be mag/pix^2) |

`xsd` |
Weighted standard deviation in x (always in units of pix) |

`ysd` |
Weighted standard deviation in y (always in units of pix) |

`covxy` |
Weighted covariance in xy (always in units of pix) |

`corxy` |
Weighted correlation in xy (always in units of pix) |

`con` |
Concentration, R50/R90 |

`asymm` |
180 degree flux asymmetry (0-1, where 0 is perfect symmetry and 1 complete asymmetry) |

`flux_reflect` |
Flux corrected for asymmetry by doubling the contribution of flux for asymmetric pixels (defined as no matching segment pixel found when the segment is rotated through 180 degrees) |

`mag_reflect` |
flux_reflect converted to mag using magzero |

`semimaj` |
Weighted standard deviation along the major axis, i.e. the semi-major first moment, so ~2 times this would be a typical major axis Kron radius (always in units of pix) |

`semimin` |
Weighted standard deviation along the minor axis, i.e. the semi-minor first moment, so ~2 times this would be a typical minor axis Kron radius (always in units of pix) |

`axrat` |
Axial ratio as given by min/maj |

`ang` |
Orientation of the semi-major axis in degrees. This has the convention that 0= | (vertical), 45= \, 90= - (horizontal), 135= /, 180= | (vertical) |

`signif` |
Approximate singificance of the detection using the Chi-Square distribution |

`FPlim` |
Approximate false-positive significance limit below which one such source might appear spuriously on an image this large |

`flux_err` |
Estimated total error in the flux for the segment |

`mag_err` |
Estimated total error in the magnitude for the segment |

`flux_err_sky` |
Sky subtraction component of the flux error |

`flux_err_skyRMS` |
Sky RMS component of the flux error |

`flux_err_shot` |
Object shot-noise component of the flux error (only if gain is provided) |

`flux_err_cor` |
Error component due to pixel correlation |

`sky_mean` |
Mean flux of the sky over all segment pixels |

`sky_sum` |
Total flux of the sky over all segment pixels |

`skyRMS_mean` |
Mean value of the sky RMS over all segment pixels |

`Nedge` |
Number of edge segment pixels that make up the outer edge of the segment |

`Nsky` |
Number of edge segment pixels that are touching sky |

`Nobject` |
Number of edge segment pixels that are touching another object segment |

`Nborder` |
Number of edge segment pixels that are touching the image border |

`Nmask` |
Number of edge segment pixels that are touching a masked pixel (note NAs in image are also treated as masked pixels) |

`edge_frac` |
Fraction of edge segment pixels that are touching the sky i.e. Nsky/Nedge, higher generally meaning more robust segmentation statistics |

`edge_excess` |
Ratio of the number of edge pixels to the expected number given the elliptical geometry measurements of the segment. If this is larger than 1 then it is a sign that the segment geometry is irregular, and is likely a flag for compromised photometry |

`flag_border` |
A binary flag telling the user which image borders the segment touches. The bottom of the image is flagged 1, left=2, top=4 and right=8. A summed combination of these flags indicate the segment is in a corner touching two borders: bottom-left=3, top-left=6, top-right=12, bottom-right=9. |

`iter` |
The iteration number when the source was flagged as having convergent flux |

`origfrac` |
The ratio between the final converged flux and the initial |

`Norig` |
Number of pixels in the non-dilated (i.e. original) segment. This will be >= pixcut by construction. |

`skyseg_mean` |
This only has a value if iterskyloc=TRUE (otherwise NA). If provided it represents the mean sky for the outer dilation annulus created when dilating, i.e. a very local estimate of the sky. To use it the fluxes and mags provided need to have the current sky (sky_sum) added back on and the new sky (skyseg_mean x N100) subtracted. |

`flag_keep` |
A suggested flag for selecting good objects. Objects flagged FALSE have hit the iteration limit and have grown their flux by more than the median for all objects at the iteration limit. This tends to suggest a problem with the sky in the location of the segment. |

Aaron Robotham

Robotham A.S.G., et al., 2018, MNRAS, 476, 3137 Haralick R.M., et al., 1973, IEEE, SMC-3 (6), 610

`profoundMakeSegim`

, `profoundMakeSegimDilate`

, `profoundMakeSegimExpand`

, `profoundMakeSegimPropagate`

, `profoundSegimStats`

, `profoundSegimPlot`

, `profoundMultiBand`

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | ```
## Not run:
image=readFITS(system.file("extdata", 'VIKING/mystery_VIKING_Z.fits', package="ProFound"))
profound=profoundProFound(image, magzero=30, verbose=TRUE, plot=TRUE)
# You can check to see if the final objects mask is aggressive enough. Notice the halos
# surrounding bright sources when just using the objects mask.
temp=image$imDat
temp[profound$objects>0]=0
magimage(temp)
temp=image$imDat
temp[profound$objects_redo>0]=0
magimage(temp)
magplot(profound$segstats[,c("R50","SB_N90")], log='x', grid=TRUE)
magplot(profound$segstats[,c("R50","SB_N90")], log='x', grid=TRUE)
magplot(profound$segstats[,c("flux","origfrac")], log='x', grid=TRUE)
## An example of a large galaxy:
VST_r=readFITS(system.file("extdata", 'VST_r.fits', package="magicaxis"))
# Running on defaults results in the central galaxy subtracting itself:
plot(profoundProFound(VST_r))
# Setting boxters=2 fixes things nicely:
plot(profoundProFound(VST_r, boxiters=2))
## End(Not run)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.