Learn R Programming

SharpeR (version 1.4.0)

sr: Create an 'sr' object.

Description

Spawns an object of class sr.

Usage

sr(
  sr,
  df,
  c0 = 0,
  ope = 1,
  rescal = sqrt(1/(df + 1)),
  epoch = "yr",
  cumulants = NULL
)

Value

a list cast to class sr.

Arguments

sr

a Sharpe ratio statistic.

df

the degrees of freedom of the equivalent t-statistic.

c0

the 'risk-free' or 'disastrous' rate of return. this is assumed to be given in the same units as x, not in 'annualized' terms.

ope

the number of observations per 'epoch'. For convenience of interpretation, The Sharpe ratio is typically quoted in 'annualized' units for some epoch, that is, 'per square root epoch', though returns are observed at a frequency of ope per epoch. The default value is 1, meaning the code will not attempt to guess what the observation frequency is, and no annualization adjustments will be made.

rescal

the rescaling parameter.

epoch

the string representation of the 'epoch', defaulting to 'yr'.

cumulants

an optional array of the higher order cumulants of the returns distribution. The first element shall be the skew; the second the excess kurtosis. Up to the sixth cumulant can be given. Higher order approximations for the moments of the Sharpe ratio can be computed based on these cumulants.

Author

Steven E. Pav shabbychef@gmail.com

Details

The sr class contains information about a rescaled t-statistic. The following are list attributes of the object:

sr

The Sharpe ratio statistic.

df

The d.f. of the equivalent t-statistic.

c0

The drag 'risk free rate' used.

ope

The 'observations per epoch'.

rescal

The rescaling parameter.

epoch

The string name of the 'epoch'.

The stored Sharpe statistic, sr is equal to the t-statistic times \(rescal * sqrt{ope}\).

For the most part, this constructor should not be called directly, rather as.sr should be called instead to compute the Sharpe ratio.

References

Sharpe, William F. "Mutual fund performance." Journal of business (1966): 119-138. https://ideas.repec.org/a/ucp/jnlbus/v39y1965p119.html

See Also

reannualize

as.sr

Other sr: as.sr(), confint.sr(), dsr(), is.sr(), plambdap(), power.sr_test(), predint(), print.sr(), reannualize(), se(), sr_equality_test(), sr_test(), sr_unpaired_test(), sr_vcov(), summary.sr

Examples

Run this code
# roll your own.
ope <- 253
zeta <- 1.0
n <- 3 * ope
rvs <- rsr(1,n,zeta,ope=ope)
roll.own <- sr(sr=rvs,df=n-1,ope=ope,rescal=sqrt(1/n))
# put a bunch in. naming becomes a problem.
rvs <- rsr(5,n,zeta,ope=ope)
roll.own <- sr(sr=rvs,df=n-1,ope=ope,rescal=sqrt(1/n))

Run the code above in your browser using DataLab