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

View source: R/profoundEllipse.R

Returns single ellipse properties for a specific set of pixels, assumed to be be a narrow range in flux (i.e. an iso-photal annulus).

1 2 |

`x` |
Numeric vector; x values of pixels. If this is a 3 column matrix then column 1 is used for x, column 2 is used for y and column 3 is used for val, see Examples. |

`y` |
Numeric vector; y values of pixels. |

`z` |
Numeric vector; z values of pixels. This is effectively the height, and would be the pixel flux for an image. |

`xcen` |
Numeric scalar; the desired x centre of the ellipse. If this is not provided it is calculated internally. |

`ycen` |
Numeric scalar; the desired y centre of the ellipse. If this is not provided it is calculated internally. |

`scale` |
How should the standard ellipse covariance be scaled to create a geometric ellipse. The default of sqrt(2) is appropriate to create an ellipse that represents the location of an iso-photal contour of a galaxy. |

`pixscale` |
Numeric scalar; the pixel scale, where pixscale=asec/pix (e.g. 0.4 for SDSS). If set to 1 (default), then the output radhi, radlo and radav is in terms of pixels, otherwise they are in arcseconds. |

`dobox` |
Logical; should boxiness be computed? If FALSE then boxiness is fixed to be 0. If TRUE then boxiness is computed (and other parameters are refined) using a maximum likelihood method. This is more expensive to compute, so the default is FALSE. |

`plot` |
Logical; should an ellipse be drawn on the current plot? This plot is generated by the |

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

The assumption is this function will largely be used by the `profoundGetEllipses`

function, but it could be useful for computing the shape of a particular iso-photal contour (see Examples).

A numeric vector with the following named elements:

`xcen` |
The flux weighted x centre of the ellipse. |

`ycen` |
The flux weighted y centre of the ellipse. |

`radhi` |
The major axis extent of the ellipse (units of pixscale, so if pixscale represents the standard asec/pix this will be asec). |

`radlo` |
The minor axis extent of the ellipse (units of pixscale, so if pixscale represents the standard asec/pix this will be asec). |

`radav` |
The average radius of the ellipse (units of pixscale, so if pixscale represents the standard asec/pix this will be asec). |

`axrat` |
The axial ratio of the ellipse as given by radlo/radhi. |

`ang` |
The angle of the ellipse in the usual ProFit sense, see |

`box` |
The boxiness of the ellipse in the usual ProFit sense, see |

`xsd` |
The flux weighted standard deviation in x (always in units of pix). |

`xsd` |
The flux weighted standard deviation in y (always in units of pix). |

`covxy` |
The flux weighted covariance in xy (always in units of pix). |

`corxy` |
The flux weighted correlation in xy (always in units of pix). |

Aaron Robotham

`profoundGetEllipses`

, `profoundGetEllipsesPlot`

1 2 3 4 5 6 7 8 9 10 11 12 13 | ```
## Not run:
# We need the ProFit library to show the profile: library(ProFit)
image = readFITS(system.file("extdata", 'KiDS/G266035fitim.fits',
package="ProFit"))$imDat
tempxy=cbind(which(image>2e-11 & image<3e-11, arr.ind=TRUE)-0.5,
image[image>2e-11 & image<3e-11])
magimage(image>2e-11 & image<3e-11)
points(tempxy[,1:2], pch='.', col='red')
tempellipse=profoundGetEllipse(tempxy)
profoundDrawEllipse(tempellipse['xcen'], tempellipse['ycen'], tempellipse['radhi'],
tempellipse['axrat'], tempellipse['ang'], col='blue')
## 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.