Anda di halaman 1dari 2

timeSeries

Rmetrics Reference Card


The functions listed in this reference card are available from the CRAN server, its development version from the r-forge Server.

timeSeries-*.R
timeSeries
Generates a signal or timeSeries from scratch
dummy
dummySeries
Creates a dummy monthly timeSeries object
dummyDailySeries Creates a dummy daily timeSeries object
getDataPart
Extracts data slot from a timeSeries object
setDataPart
Assigns data slot of a timeSeries object
isOHLC
.isOHLC
Tests if a series has Open-High-Low-Close columns
.isOHLCV
Tests if a series has Open-High-Low-Close-Volume
isRegular
Tests if a time series is a regular series
isDaily
Tests if a timeSeries is a daily series
isMonthly
Tests if a timeSeries is a monthly series
isQuarterly
Tests if a timeSeries is a quarterly series
frequency
Returns the frequency of a regular time series
isUnivariate
Tests if a timeSeries object is univariate
isMultivariate Tests if a timeSeries object is multivariate
readSeries
Reads a CSV file and creates a timeSeries
signalCounts
.signalCounts
Creates charvec for integer indexed time stamps
slotFinCenter
finCenter
Extracts financial center slot from a timeSeries
finCenter<Assigns financial center slot from a timeSeries
getFinCenter
Extracts financial center slot from a timeSeries
setFinCenter<- Assigns new financial center slot from a timeSeries
slotSeries
series
Extracts data slot from a timeSeries object
series<Assigns new data slot to a timeSeries object
getSeries
Extracts data slot from a timeSeries object
setSeries<Assigns new data slot to a timeSeries object
slotTime
time
Extracts time stamps from a timeSeries object
time<Assigns time samps to a timeSeries object
getTime
Extracts time stamps from a timeSeries object
setTime<Assigns time samps to a timeSeries object
slotUnits
getUnits
Extracts units slot from a timeSeries
setUnits<Assigns new units slot to a timeSeries

base-*.R
apply
attach
cbind
rbind
comment
diff
dim
dim<dimnames
dimnames
colnames
rownames
colnames<rownames<names
names<merge
rank
rev
sample
scale
sort
start
end

Time Series Functions:

Base Time Series Functions:


Applies a function to blocks of a timeSeries
Attaches a timeSeries to the search path
Binds columns of two timeSeries objects
Binds rows of two timeSeries objects
Returns documentation slot of a time series
Differences a timeSeries object
Returns dimension of a timeSeries object
Assigns dimension of a timeSeries object
Returns dimension names of a time series
Assigns dimension names of a timeSeries object
Returns column names to a timeSeries object
Returns row names to a timeSeries object
Assigns column names to a timeSeries object
Assigns row names to a timeSeries object
Returns column names of a timeSeries object
Assigns column names of a timeSeries object
Merges two timeSeries objects
Returns sample ranks of a timeSeries object
Reverts a time series in the time stamps
Resamples a time series in its time stamps
Centers and/or scales a timeSeries object
Sorts a time series in its time stamps
Extracts start date of a timeSeries object
Extracts end date of a timeSeries object

Subsetting:
base-*.R:
subset
.subset_
.findIndex
[
[<$
$<t

Subsets timeSeries objects


Index search
Subsets a timeSeries object
Assigns value to subsets of a time series
Subsets a time series by column names
Replaces subset by column names
Returns the transpose of a timeSeries object

Methods:

Statistics Time Series Functions:

methods-*.R
as.timeSeries
as.*.default
as.*.ts
as.*.data.frame
a.s*.character
as.*.zoo
as.vector.*
as.matrix.*
as.numeric.*
as.data.frame.*
as.ts.*
as.ts.logical
as.list.*
comment
comment<is
is.timeSeries
mathops
Ops,timeSeries
cummax
cumin
cumprod
cumsum
quantile
plot
lines
points
show
print

Defines method for a timeSeries object


Returns the input
Transforms a 'data.frame' into a timeSeries
Transforms a 'data.frame' into a timeSeries
Loads and transformas from a demo file
Transforms a 'zoo' object into a timeSeries
Converts a univariate timeSeries to a vector
Converts a timeSeries to a 'matrix'
Converts a timeSeries to a 'numeric'
Converts a timeSeries to a 'data.frame'
Converts a timeSeries to a 'ts'
Converts a timeSeries to 'logical'
Converts a timeSeries to 'list'
Note: Replace * by timeSeries
Gets documentation slot of a timeSeries object
Set documentation slot of a timeSeries object
Tests for a timeSeries object
Returns group 'Ops' for a timeSeries object
Returns cumulated maxima from a timeSeries
Returns cumulated minima from a timeSeries
Returns cumulated products from a timeSeries
Returns cumulated sums from a timeSeries
Returns sample qunatile of a timeSeries
Plots a timeSeries object
Adds lines to a timeSeries plot
Adds points to a timeSeries plot
Prints a timeSeries object
Prints a timeSeries object

statistics-*.R
colCumsums
colCummaxs
colCummins
colCumprods
colCumreturns
colSums
colMeans
colSds
colVars
colSkewness
colKurtosis
colMaxs
colMins
colProds
colStats
orderColnames
sortColnames
sampleColnames
pcaColnames
hclustColnames
statsColnames
orderStatistics
rollMean
rollMin
rollMax
rollMedian
rollStats
rowCumsums
smoothLowess
smoothSupsmu
smoothSpline

Computes cumulated sums of a timeSeries by column


Computes cumulated maximum values by column
Computes cumulated maximum values by column
Computes cumulated product values by column
Computes cumulated product values by column
Computes sums of all values in each column
Computes means of all values in each column
Computes standardard deviation of each column
Computes sample variance by column
Computes sample skewness by column
Computes sample kurtosis by column
Computes maximum values in each column
Computes minimum values in each column
Computes product of all values in each column
Computes sample statistics by column
Returns ordered column names of a timeSeries
Returns sorted column names of a timeSeries
Returns sampled column names of a timeSeries
Returns PCA correlation ordered column names
Returns hierarchical clustered column names
Returns statistically rearranged column names
Computes order statistics of a timeSeries
Computes rolling mean of a timeSeries
Computes rolling minimum of a timeSeries
Computes rolling maximum of a timeSeries
Computes rolling median of a timeSeries
Computes rolling statistics of a timeSeries
Computes cumulated sums of a time series by row
Smoothes a series with lowess function
Smoothes a series with supsmu function
Smoothes a series with smooth.spline function

Financial Time Series Functions:


fin-*.R:
align
Cumulated
daily
alignDailySeries
rollDailySeries
drawdowns
drawdownsStats
durations
monthly
countMonthlyRecords
rollMonthlyWindows
rollMonthlySeries
periodical
.endOfPeriodSeries
.endOfPeriodStats
.endOfPeriodBenchmarks
returns
runlengths
splits
outlier
spreads
midquotes
turnpoints
turns
turnsStats

Rmetrics Association
www.rmetrics.org
March 2012

Aligns a time series to time stamps


Computes cumulated series from financial returns
Aligns a time series to new positions
Rolls daily a timeSeries on a given period
Generates a time series of drawdown levels
Computes drawdown statistics from a timeSeries
Computes durations from a timeSeries
Returns a series with monthly counts of records
Returns start/end dates for rolling time windows
Rolls Monthly a timeSeries on a given period
Returns series back to a given period
Returns statistics back to a given period
Returns benchmarks back to a given period
Computes returns from a index/price/value series
Returns a timeSeries of runlengths
Detects timeSeries splits by outlier detection
Computes spreads between bivariate timeSeries
Computes mid quotes of bivariate timeSeries
Returns peaks and pits from a timeSeries
Computes turnpoints statistics for a timeSeries

Misc. Time Series Functions:


stats-*.R:
aggregate
filter
lag
na.contignous
na.omit
window

Aggregates a time series by calendarical blocks


Applies linear filtering to a timeSeries
Computes a lagged version of a timeSeries
Finds longest consecutive of non-missing values
Handles missing values in a timeSeries
Subtracts a piece or a window from a timeSeries



Utility Functions:
utils-*.R:
Description
getArgs
head
tail
str

Sets default description string


Extracts arguments from a timeSeries function
Returns the head of a timeSeries object
Returns the tail of a timeSeries object
Displays the structure of a timeSeries object