| print-methods {timeSeries} | R Documentation |
Print 'timeSeries' objects.
## S4 method for signature 'timeSeries'
show(object)
## S4 method for signature 'timeSeries'
print(x, FinCenter = NULL, format = NULL,
style = c("tS", "h", "ts"), by = c("month", "quarter"), ...)
object, x |
an object of class |
FinCenter |
a character with the the location of the financial center named as "continent/city". |
format |
the format specification of the input character vector, a character string with the format in POSIX notation. |
style |
a character string, one of |
by |
a character string, one of |
... |
arguments passed to other methods. |
show does not have additional arguments.
The print method allows to modify the way the object is shown
by explicitly calling print.
The default for style is tS. For univariate time series
the style = "h" causes the object to be printed as a vector
with the time stamps as labels. Finally, style = "ts" like
objects from base R class "ts". The last value is suitable for
quarterly and monthly time series.
Prints an object of class timeSeries.
## Load Micsrosoft Data -
setRmetricsOptions(myFinCenter = "GMT")
LPP <- MSFT[1:12, 1:4]
## Abbreviate Column Names -
colnames(LPP) <- abbreviate(colnames(LPP), 6)
## Print Data Set -
print(LPP)
## Alternative Use, Show Data Set -
show(LPP)
## a short subseries to demo 'print'
hC <- head(MSFT[ , "Close"])
class(hC)
print(hC)
print(hC, style = "h")