[Blotter-commits] r1551 - in pkg/blotter: . R man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sat Oct 26 21:30:50 CEST 2013
Author: braverock
Date: 2013-10-26 21:30:49 +0200 (Sat, 26 Oct 2013)
New Revision: 1551
Modified:
pkg/blotter/.Rbuildignore
pkg/blotter/NAMESPACE
pkg/blotter/R/tradeStats.R
pkg/blotter/man/dailyTxnPL.Rd
Log:
- add more documentation for dailyTxnPL and dailyEqPL
Modified: pkg/blotter/.Rbuildignore
===================================================================
--- pkg/blotter/.Rbuildignore 2013-10-24 19:13:56 UTC (rev 1550)
+++ pkg/blotter/.Rbuildignore 2013-10-26 19:30:49 UTC (rev 1551)
@@ -1 +1,3 @@
R/.vimrc
+^.*\.Rproj$
+^\.Rproj\.user$
Modified: pkg/blotter/NAMESPACE
===================================================================
--- pkg/blotter/NAMESPACE 2013-10-24 19:13:56 UTC (rev 1550)
+++ pkg/blotter/NAMESPACE 2013-10-26 19:30:49 UTC (rev 1551)
@@ -1,4 +1,3 @@
-useDynLib(blotter)
export(.getPortfolio)
export(AcctReturns)
export(PortfReturns)
@@ -36,3 +35,4 @@
export(updateEndEq)
export(updatePortf)
importFrom(zoo,as.Date)
+useDynLib(blotter)
Modified: pkg/blotter/R/tradeStats.R
===================================================================
--- pkg/blotter/R/tradeStats.R 2013-10-24 19:13:56 UTC (rev 1550)
+++ pkg/blotter/R/tradeStats.R 2013-10-26 19:30:49 UTC (rev 1551)
@@ -224,11 +224,19 @@
#'
#' designed to collate information for high frequency portfolios
#'
+#' If you do not pass \code{Symbols}, then all symbols in the provided
+#' \code{Portfolios} will be used.
+#'
+#' The daily P&L is calculated from \code{Net.Txn.Realized.PL} if by
+#' \code{dailyTxnPL}
+#' and from \code{Net.Trading.PL} by \code{dailyEqPL}
+#'
#' @aliases dailyEqPL
#' @param Portfolios portfolio string
#' @param Symbols character vector of symbol strings
#' @param drop.time remove time component of POSIX datestamp (if any), default TRUE
#' @author Brian G. Peterson
+#' @return a multi-column \code{xts} time series, one column per symbol, one row per day
#' @seealso tradeStats
#' @export
dailyTxnPL <- function(Portfolios, Symbols, drop.time=TRUE)
Modified: pkg/blotter/man/dailyTxnPL.Rd
===================================================================
--- pkg/blotter/man/dailyTxnPL.Rd 2013-10-24 19:13:56 UTC (rev 1550)
+++ pkg/blotter/man/dailyTxnPL.Rd 2013-10-26 19:30:49 UTC (rev 1551)
@@ -15,10 +15,22 @@
\item{drop.time}{remove time component of POSIX datestamp
(if any), default TRUE}
}
+\value{
+ a multi-column \code{xts} time series, one column per
+ symbol, one row per day
+}
\description{
designed to collate information for high frequency
portfolios
}
+\details{
+ If you do not pass \code{Symbols}, then all symbols in
+ the provided \code{Portfolios} will be used.
+
+ The daily P&L is calculated from
+ \code{Net.Txn.Realized.PL} if by \code{dailyTxnPL} and
+ from \code{Net.Trading.PL} by \code{dailyEqPL}
+}
\author{
Brian G. Peterson
}
More information about the Blotter-commits
mailing list