Version: | 0.0.1.7 |
Title: | Reduction of Speckle Data from BTA 6-m Telescope |
Description: | A set of functions for obtaining positional parameters and magnitude difference between components of binary and multiple stellar systems from series of speckle images. |
Author: | Denis Rastegaev |
Maintainer: | Denis Rastegaev <drastega@gmail.com> |
URL: | https://drastega.github.io/docs/specklestar_vignette.html |
BugReports: | https://github.com/drastega/specklestar/issues |
Depends: | R (≥ 3.0.0) |
Imports: | Rcpp |
Suggests: | imager, tidyverse, rgl, fftw, mrbsizeR, knitr, rmarkdown |
License: | GPL-2 |
NeedsCompilation: | yes |
SystemRequirements: | fftw3 (>= 3.1.2) |
Encoding: | UTF-8 |
LazyData: | true |
LinkingTo: | Rcpp |
RoxygenNote: | 6.0.1 |
VignetteBuilder: | knitr |
Packaged: | 2018-02-08 13:50:57 UTC; leda |
Repository: | CRAN |
Date/Publication: | 2018-02-08 18:14:49 UTC |
specklestar: A package for reduction of speckle data.
Description
The specklestar package provides functions for obtaining power spectrum and autocorrelation function from speckle data.
Middle frame
Description
Average image of the series of 512 x 512 px images
Usage
middle_frame(filename, subtrahend, threshold = 50000L)
Arguments
filename |
A string. |
subtrahend |
512 x 512 matrix to subtract. |
threshold |
An integer (default 50000). |
Value
The 512 x 512 matrix of middle speckle image.
Examples
obj_filename <- system.file("extdata", "ads15182_550_2_frames.dat", package = "specklestar")
zero_matrix <- matrix(0, 512, 512)
mf <- middle_frame(obj_filename, subtrahend = zero_matrix)
Autocorrelation function calculation
Description
Autocorrelation function of power spectrum
Usage
speckle_acf(ps)
Arguments
ps |
513 x 1024 power spectrum double matrix. |
Value
The 513 x 1024 double matrix of ACF.
Examples
obj_filename <- system.file("extdata", "ads15182_550_2_frames.dat", package = "specklestar")
pow_spec_diff <- speckle_ps_diff(obj_filename)
acf <- speckle_acf(pow_spec_diff)
Get selected speckle frame Get specified speckle frame as matrix from file
Description
Get selected speckle frame Get specified speckle frame as matrix from file
Usage
speckle_frame(data_file = file.choose(), frame = 1)
Arguments
data_file |
a character string with the path name to a file. |
frame |
an integer. |
Value
512 x 512 matrix with given frame.
Examples
## Not run:
# On Unix-like operating systems only
# Read frame number 2 from file to matrix
obj_filename <- system.file("extdata", "ads15182_550_2_frames.dat", package = "specklestar")
frame2 <- speckle_frame(obj_filename, 2)
## End(Not run)
Speckle Generator
Description
Generate model 512 x 512 x 2 (bytes) speckle image of binary star
Usage
speckle_generator(rho, theta, dm, seeing, speckle_sigma, wind)
Arguments
rho |
a separation (an arcsec). |
theta |
a positional angle. |
dm |
a magnitude difference. |
seeing |
a number. |
speckle_sigma |
a number. |
wind |
a wind speed. |
Value
The vector of model speckle image.
Examples
speckle_vector <- speckle_generator(rho = 0.5, theta = 70,
dm = 0.3, seeing = 20, speckle_sigma = 1, wind = 0)
speckle_matrix <- matrix(speckle_vector, nrow = 512, ncol = 512)
Power spectrum calculation
Description
Power spectrum of the series of 512 x 512 speckle images
Usage
speckle_ps(filename, dark, flat, threshold = 50000L)
Arguments
filename |
a character string with the path name to a file. |
dark |
512 x 512 middle frame matrix. |
flat |
512 x 512 middle flat field matrix. |
threshold |
an integer (default is 50000). |
Value
The 513 x 1024 double matrix of power spectrum.
Examples
obj_filename <- system.file("extdata", "ads15182_550_2_frames.dat", package = "specklestar")
midd_dark <- matrix(0, 512, 512)
midd_flat <- matrix(1, 512, 512)
pow_spec <- speckle_ps(obj_filename, dark = midd_dark, flat = midd_flat)
Power spectrum calculation
Description
Power spectrum of the difference of neighboring frames in the series of speckle images
Usage
speckle_ps_diff(filename, threshold = 50000L)
Arguments
filename |
a character string with the path name to a file. |
threshold |
an integer (default is 50000). |
Value
The 513 x 1024 double matrix of power spectrum.
Examples
obj_filename <- system.file("extdata", "ads15182_550_2_frames.dat", package = "specklestar")
pow_spec_diff <- speckle_ps_diff(obj_filename)
Statistics of speckles
Description
Calculate statistics of speckles in the series of 512 x 512 speckle images and filter "bad" frames
Usage
speckle_stat(filename, threshold = 50000L)
Arguments
filename |
a character string with the path name to a file. |
threshold |
an integer (default is 50000). |
Value
The list with 2 elements 'badFrames' and 'hist':
1 number of bad frames,
2 double vector of speckle statistics.
Examples
obj_filename <- system.file("extdata", "ads15182_550_2_frames.dat", package = "specklestar")
spec_stat <- speckle_stat(obj_filename)