[Blotter-commits] r1695 - in pkg/blotter: . R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sun Aug 9 23:13:50 CEST 2015


Author: bodanker
Date: 2015-08-09 23:13:49 +0200 (Sun, 09 Aug 2015)
New Revision: 1695

Added:
   pkg/blotter/R/blotter-package.R
Modified:
   pkg/blotter/DESCRIPTION
   pkg/blotter/NAMESPACE
   pkg/blotter/R/tradeStats.R
Log:
Clean up namespace

Make namespace closer to what's expected by CRAN, so users will have
potentially fewer issues with namespace clashes from CRAN packages
(e.g. dplyr::lag).

Move zoo to imports and import all functions used that are in non-base
packages that are distributed with R (e.g. utils, graphics, etc). Re-
roxygenize NAMESPACE file.

Add R/blotter-package.R file to hold roxygen import directives. Need to
move contents of man/blotter-package.Rd to this new file.

Bump version.


Modified: pkg/blotter/DESCRIPTION
===================================================================
--- pkg/blotter/DESCRIPTION	2015-08-09 16:39:58 UTC (rev 1694)
+++ pkg/blotter/DESCRIPTION	2015-08-09 21:13:49 UTC (rev 1695)
@@ -2,7 +2,7 @@
 Type: Package
 Title: Tools for transaction-oriented trading systems
     development.
-Version: 0.9.1666
+Version: 0.9.1695
 Date: $Date$
 Author: Peter Carl, Brian G. Peterson
 Maintainer: Brian G. Peterson <brian at braverock.com>
@@ -16,10 +16,15 @@
 Depends:
     R (>= 2.15),
     xts (>= 0.7-6.17),
-    zoo,
     FinancialInstrument(>= 0.6.3),
     PerformanceAnalytics,
     quantmod
+Imports:
+    zoo,
+    graphics,
+    methods,
+    stats,
+    utils
 Suggests:
     Hmisc,
     RUnit,

Modified: pkg/blotter/NAMESPACE
===================================================================
--- pkg/blotter/NAMESPACE	2015-08-09 16:39:58 UTC (rev 1694)
+++ pkg/blotter/NAMESPACE	2015-08-09 21:13:49 UTC (rev 1695)
@@ -1,4 +1,4 @@
-# Generated by roxygen2 (4.0.2): do not edit by hand
+# Generated by roxygen2 (4.1.1): do not edit by hand
 
 export(.getPortfolio)
 export(AcctReturns)
@@ -36,5 +36,23 @@
 export(updateAcct)
 export(updateEndEq)
 export(updatePortf)
-importFrom(zoo,as.Date)
+import(FinancialInstrument)
+import(PerformanceAnalytics)
+import(quantmod)
+import(xts)
+import(zoo)
+importFrom(graphics,abline)
+importFrom(graphics,grid)
+importFrom(graphics,plot)
+importFrom(graphics,points)
+importFrom(methods,hasArg)
+importFrom(stats,lag)
+importFrom(stats,median)
+importFrom(stats,na.omit)
+importFrom(stats,quantile)
+importFrom(stats,sd)
+importFrom(stats,start)
+importFrom(utils,View)
+importFrom(utils,head)
+importFrom(utils,tail)
 useDynLib(blotter)

Added: pkg/blotter/R/blotter-package.R
===================================================================
--- pkg/blotter/R/blotter-package.R	                        (rev 0)
+++ pkg/blotter/R/blotter-package.R	2015-08-09 21:13:49 UTC (rev 1695)
@@ -0,0 +1,6 @@
+#'@import FinancialInstrument PerformanceAnalytics quantmod xts zoo
+#'@importFrom graphics abline grid plot points
+#'@importFrom methods hasArg
+#'@importFrom stats lag median na.omit quantile sd start
+#'@importFrom utils View head tail
+NULL

Modified: pkg/blotter/R/tradeStats.R
===================================================================
--- pkg/blotter/R/tradeStats.R	2015-08-09 16:39:58 UTC (rev 1694)
+++ pkg/blotter/R/tradeStats.R	2015-08-09 21:13:49 UTC (rev 1695)
@@ -48,7 +48,6 @@
 #' @param inclZeroDays TRUE/FALSE, whether to include zero P&L days in daily calcs, default FALSE for backwards compatibility.
 #' @author Lance Levenson, Brian Peterson
 #' @export
-#' @importFrom zoo as.Date
 #' @return
 #' a \code{data.frame} containing:
 #'  



More information about the Blotter-commits mailing list