找回密码
 注册
查看: 357|回复: 0

R语言 sapa包 SDF()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-9-29 22:14:51 | 显示全部楼层 |阅读模式
SDF(sapa)
SDF()所属R语言包:sapa

                                        Nonparametric (cross) spectral density function estimation
                                         非参数谱密度函数估计(交叉)

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

Estimate the process (cross) spectral density function via nonparametric
估计过程(交叉)通过非参数谱密度函数


用法----------Usage----------


    n.taper=5, overlap=0.5, blocksize=NULL,
    single.sided=TRUE, sampling.interval=NULL,



参数----------Arguments----------

参数:x
a vector or matrix containing uniformly-sampled real-valued time series. If a matrix, each column should contain a different time series.
的向量或矩阵含有均匀采样的实值的时间序列。如果一个的matrix,每列包含不同的时间序列。


参数:blocksize
an integer representing the number of points (width) of each block in the WOSA estimator scheme. Default: floor(N/4) where N is the number of samples in each series.
一个整数,表示每块的点数(宽)在WOSA估计计划。默认值:floor(N/4)其中N是在每个系列的样本数。


参数:center
a logical value. If TRUE, the mean of each time series is recentered prior to estimating the SDF. Default: TRUE.
一个逻辑值。如果TRUE,平均每个时间序列recentered之前估计的SDF。默认值:TRUE。


参数:method
a character string denoting the method to use in estimating the SDF. Choices are "direct", "lag window", "wosa" (Welch's Overlapped Segment Averaging), "multitaper". See DETAILS for more information. Default: "direct".
一个字符串,表示估计日本自卫队所使用的方法。选择是"direct","lag window","wosa"(韦尔奇的交迭段平均),"multitaper"。详情请参阅更多信息。默认值:"direct"。


参数:n.taper
an integer defining the number of tapers to use in a multitaper scheme. This value is overwritten if the taper input is of class taper. Default: 5.
一个整数,定义的数量逐渐变细的多窗口计划。类taper如果taper输入该值将被覆盖。默认值:5。


参数:npad
an integer representing the total length of each time series to analyze after padding with zeros. This argument allows the user to control the spectral resolution of the SDF estimates: the normalized frequency interval is deltaf=1/npad. This argument must be set such that npad > 2. Default: 2*numRows(x).
一个整数,代表每个时间序列分析后,用零填充的总长度。该参数允许用户控制的光谱分辨率自卫队的估计:归一化频率间隔为deltaf=1/npad。这个参数必须设置成npad > 2。默认值:2*numRows(x)。


参数:overlap
a numeric value on [0,1] denoting the fraction of window overlap for the WOSA estimator. Default: 0.5.
[0,1]表示的窗口重叠的分数的WOSA估计的一个数值上。默认值:0.5。


参数:recenter
a logical value. If TRUE, the mean of each time series is recentered after (posssibly) tapering the series prior to estimating the SDF. Default: FALSE.
一个逻辑值。如果TRUE,平均每个时间序列recentered后(专注于)逐渐变细的系列之前,估计日本自卫队。默认值:FALSE。


参数:sampling.interval
a numeric value representing the interval between samples in the input time series x. Default: NULL, which serves as a flag to obtain the sampling interval via the deltat function. If x is a list, the default sampling interval is deltat(x[[1]]). If x is an atomic vector (ala isVectorAtomic), then the default samplign interval is established ala deltat(x). Finally, if the input series is a matrix, the sampling interval of the first series (assumed to be in the first column) is obtained ala deltat(x[,1]).
一个数字值,该值表示样本之间的时间间隔中的输入时间系列x。默认值:NULL,它作为一个标志,以获得通过deltat函数的采样间隔。如果x是一个列表,默认的采样间隔是deltat(x[[1]])。如果x是的原子向量(ALAisVectorAtomic),然后的默认samplign间隔建立阿拉deltat(x)。最后,如果输入序列是一个矩阵,得到的第一个系列的采样间隔(假定为在第一列中)鼻翼deltat(x[,1])。


参数:single.sided
a logical value. If TRUE, a single-sided SDF estimate is returned corresponding to the normalized frequency range of [0,1/2]. Otherwise, a double-sided SDF estimate corresponding to the normalized frequency interval [-1/2,1/2] is returned. Default: TRUE.
一个逻辑值。如果TRUE,一个单面的SDF估计返回对应的归一化频率范围[0,1/2]。否则,一个双面自卫队估计对应的归一化的频率间隔[-1/2,1/2]被返回。默认值:TRUE。


参数:taper.
an object of class taper or a character string denoting the primary taper. If an object of class taper, the length of the taper is checked to ensure compatitbility with the input x. See DETAILS for more information. The default values are a function of the method as follows:   
对象的类taper或字符串表示的主要锥度。如果一个对象类taper,长度的锥度检查,以确保compatitbility与输入x。详情请参阅更多信息。默认值是一个函数的method如下:

directnormalized rectangular taper
directnormalized矩形锥




lag windownormalized Parzen window with a cutoff at N/2 where N is the length of the time series.
落后windownormalized Parzen窗的截止在N/2其中N是时间序列的长度。




wosanormalized Hanning taper
wosanormalized寒凝锥度




multitapernormalized Hanning taper  
multitapernormalized寒凝锥度


参数:window
an object of class taper or a character string denoting the (secondary) window for the lag window estimator. If an object of class taper, the length of the taper is checked to ensure compatitbility with the input x. See DETAILS for more information. Default: Normalized Hanning window.
对象的类taper或字符串表示的滞后窗口估计窗口(二级)。如果一个对象类taper,长度的锥度检查,以确保compatitbility与输入x。详情请参阅更多信息。默认值:归汉宁窗。


Details

详细信息----------Details----------

Let x(t) be a uniformly sampled real-valued time series of length N, Let an estimate of the process spectral density function be denoted as S(f) where f are frequencies on the interval -1/(2*deltat),1/(2*deltat) where deltat is the sampling interval. The supported SDF estimators are:
让x(t)是一个均匀采样的实值的时间序列的长度N,让过程谱密度函数的估计值被表示为S(f)f上的频率间隔-1/(2*deltat),1/(2*deltat)deltat是采样间隔。支持的的的SDF估计是:

  


directThe direct SDF estimator is defined as S(f)=|sum[t=0,...,N-1]{h(t)*x(t)*exp(-i*2*pi*f*t)}|^2, where h(t) is a data taper normalized such that sum[t=0,...,N-1]{h(t)^2} = 1. If h(t)=1/sqrt(N) then we obtain the definition of the periodogram S(f)=(1/N) * |sum[t=0,...,N-1]{x(t)*exp(-i*2*pi*f*t)}|^2. See the taper function for more details on supported window types.
directThe直接SDF估计被定义为S(f)=|sum[t=0,...,N-1]{h(t)*x(t)*exp(-i*2*pi*f*t)}|^2,h(t)是一个数据锥度归一化,这sum[t=0,...,N-1]{h(t)^2} = 1。如果h(t)=1/sqrt(N)然后我们得到的周期图S(f)=(1/N) * |sum[t=0,...,N-1]{x(t)*exp(-i*2*pi*f*t)}|^2的定义。支持的窗口类型的详细信息,请参阅“taper功能。




lag windowThe lag window SDF estimator is defined as S(f)=sum[k=-(N-1),...,(N-1)]{w(k)*s(k)*exp(-i*2*pi*f*k)}|^2, where s(k) is the autocovariance sequence estimator corresponding to some direct spectral estimator (often the periodogram) and w(k) is a lag window (popular choices are the Parzen, Papoulis, and Daniell windows). See the taper function for more details.
滞后windowThe滞后窗口SDF估计被定义为S(f)=sum[k=-(N-1),...,(N-1)]{w(k)*s(k)*exp(-i*2*pi*f*k)}|^2,其中s(k)是相应的一些直接谱估计(通常是周期图)和自相关序列估计w(k)是一个滞后窗口(流行的选择Parzen窗,Papoulis,和丹尼尔窗口)。请参阅taper功能的更多详细信息,。




wosa Welch's Overlapped Segment Averaging SDF estimator is defined as
WOSA韦尔奇的交迭段被定义为平均SDF估计

<p align="center">S(l,f) =|sum[t=0,...,Ns-1]{h(t)*x(t+l)*exp(-i*2*pi*f*t)}|^2
<p ALIGN="CENTER"> S(l,f) =|sum[t=0,...,Ns-1]{h(t)*x(t+l)*exp(-i*2*pi*f*t)}|^2




multitaper A multitaper spectral estimator is given by
多窗口给出了一个多窗口谱估计

<p align="center">See reference(s) for further details.
<p ALIGN="CENTER"> See reference(s) for further details.

Cross spectral density function estimation: If the input x is a matrix, where each column contains a different time series, then the results are returned in a matrix whose columns correspond to all possible unique combinations of cross-SDF estimates. For example, if x has three columns, then the output will be a matrix whose columns are {S11, S12, S13, S22, S23, S33} where Sij is the cross-SDF estimate of the ith and jth column of x. All cross-spectral density function estimates are returned as complex-valued series to maintain the phase relationships between components. For all Sij where i=j, however, the imaginary portions will be zero (up to a numerical noise limit).
交叉谱密度函数估计:如果输入x是一个矩阵,每一列都包含不同的时间序列,然后将结果返回的列的矩阵-SDF估计,对应于所有可能的独特的组合。例如,如果x有三列,那么输出将是一个矩阵的列{S11, S12, S13, S22, S23, S33}Sij是跨SDF估计i个 j的x列。复值系列的所有交叉谱密度函数估计返回保持组件之间的相位关系。对于所有Siji=j,然而,虚数部将是零(最多到一个数值的噪声限制)。


值----------Value----------

an object of class SDF.
对象类SDF。


S3方法----------S3 METHODS----------

  


as.matrixconverts the (cross-)SDF estimate(s) as a matrix. Optional arguments are passed directly to the matrix function during the conversion.
as.matrixconverts(交叉),SDF估计()作为基质。在转换过程中,可选的参数直接传递给matrix的函数。




plotplots the (cross-)SDF estimate(s). Optional arguments are:   
plotplots(跨)SDF预算()。可选参数如下:

xscale a character string defining the scaling to perform on the (common) frequency vector of the SDF estimates. See the scaleData function for supported choices. Default: "linear".
xscale的一个字符串,定义扩展到执行(普通)频率矢量自卫队的估计。见scaleData功能,支持选择。默认值:"linear"。




yscalea character string defining the scaling to perform on the SDF estimates. See the scaleData function for supported choices. Default: "linear".
yscalea字符串的定义扩展到执行的SDF估计。见scaleData功能,支持选择。默认值:"linear"。




typea single character defining the plot type (ala the par function) of the SDF plots. Default: ifelse(numRows(x) > 100, "l", "h").
A型单字符定义的SDF图的图类型(阿拉par的函数)。默认值:ifelse(numRows(x) > 100, "l", "h")。




xlaba character string representing the x-axis label. Default: "FREQUENCY (Hz)".
xlaba字符的字符串,它表示x轴的标签。默认值:"FREQUENCY (Hz)"。




ylaba (vector of) character string(s), one per (cross-)SDF estimate, representing the y-axis label(s). Default: in the multivariate case, the strings "Sij" are used for the y-axis labels, where i and j are the indices of the different variables. For example, if the user supplies a 2-column matrix for x, the labels "S11", "S12", and "S22" are used to label the y-axes of the corresponding (cross-)SDF plots. In the univariate case, the default string "SDF" prepended with a string describing the type of SDF performed (such as "Multitaper") is used to label the y-axis.
ylaba(矢量)字符的字符串(s),每一个(交叉)SDF估计,代表y轴标签()。默认值:在多变量的情况下,字符串"Sij"用于为y轴的标签,其中i和j是不同的变量的指数,其中。例如,如果用户提供了一个2列的矩阵x,标签"S11","S12",和"S22"用于标记的y-轴的相应的(交叉)SDF图。在单因素的情况下,默认的字符串"SDF"前面加上一个字符串来描述的类型SDF执行(如"Multitaper")用于y轴的标签。




plot.meana logical value. If TRUE, the SDF value at normalized frequency f=0 is plotted for each SDF. This frequency is associated with the sample mean of the corresponding time series. A relatively large mean value dominates the spectral patterns in a plot and thus the corresponding frequency is typically not plotted. Default: !attr(x,"center").
plot.meana逻辑值。如果TRUE,日本自卫队值归一化频率f=0绘制每个SDF。此频率与样本相关联的对应的时间系列的意思。一个比较大的的平均值占主导地位的光谱模式的图,因此通常不绘制相应的频率。默认值:!attr(x,"center")。




n.plotan integer defining the maximum number of SDF plots to place onto a single graph. Default: 3.
n.plotan整数定义的最大数量的SDF图放置到一个单一的图形。默认值:3。




FUNa post processing function to apply to the SDF values prior to plotting. Supported functions are Mod, Im, Re and Arg. See each of these functions for details. If the SDF is purely real (no cross-SDF is calculated), this argument is coerced to the Mod function. Default: Mod.
FUNa后处理功能,适用于前日本自卫队值,绘制。支持的功能Mod,Im,Re和Arg。有关详细信息,请参阅这些功能。如果日本自卫队纯粹是真正的(无交叉SDF计算),此参数被强制为Mod功能。默认值:Mod。




addA logical value. If TRUE, the plot is added using the current par() layout. Otherwise a new plot is produced. Default: FALSE.
ADDA逻辑值。如果TRUE,该图使用当前par()布局添加。否则,产生一个新的绘图。默认值:FALSE。




...additional plot parameters passed directly to the genPlot function used to plot the SDF estimates.   
额外的地积参数直接传递给genPlot函数用于绘制自卫队的估计。




printprints the object. Available options are:   
printprints对象。可用选项有:

justify text justification ala prettPrintList. Default: "left".
对齐文本理由阿拉prettPrintList。默认值:"left"。




sepheader separator ala prettyPrintList. Default: ":".
sepheader分离鼻翼prettyPrintList。默认值:":"。




...Additional print arguments sent directly to the prettyPrintList function.   
的附加打印参数直接发送到prettyPrintList功能。

  



参考文献----------References----------

Percival, Donald B. and Constantine, William L. B. (2005) &ldquo;Exact Simulation of Gaussian Time Series from Nonparametric Spectral Estimates with Application to Bootstrapping", Journal of Computational and Graphical Statistics, accepted for publication.
D.B. Percival and A. Walden (1993), Spectral Analysis for Physical Applications: Multitaper and Conventional Univariate Techniques, Cambridge University Press, Cambridge, UK.

参见----------See Also----------


实例----------Examples----------


## calculate various SDF estimates for the [#计算各种SDF估计]
## sunspots series. remove mean component for a [#太阳黑子系列。删除意味着组件的]
## better comparison. [#更好的比较。]
data <- as.numeric(sunspots)
methods <- c("direct","wosa","multitaper",
    "lag window")

S <- lapply(methods, function(x, data) SDF(data, method=x), data)
x <- attr(S[[1]], "frequency")[-1]
y <- lapply(S,function(x) decibel(as.vector(x)[-1]))
names(y) <- methods

## create a stack plot of the data [#创建一个堆栈的数据曲线]
stackPlot(x, y, col=1:4)

## calculate the cross-spectrum of the same [#计算相同的交叉谱]
## series: all spectra should be the same in [#系列:所有的光谱应该是相同的]
## this case [#这种情况下,]
SDF(cbind(data,data), method="lag")

## calculate the SDF using npad=31 [使用NPAD = 31#计算SDF]
SDF(data, npad=31, method="multitaper")

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2024-11-29 13:47 , Processed in 0.030014 second(s), 15 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表