[Eventstudies-commits] r314 - pkg/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sat May 10 08:57:28 CEST 2014


Author: chiraganand
Date: 2014-05-10 08:57:27 +0200 (Sat, 10 May 2014)
New Revision: 314

Modified:
   pkg/R/eventstudy.R
Log:
Added a warning if there are model arguments supplied when type is None.

Modified: pkg/R/eventstudy.R
===================================================================
--- pkg/R/eventstudy.R	2014-05-09 17:34:22 UTC (rev 313)
+++ pkg/R/eventstudy.R	2014-05-10 06:57:27 UTC (rev 314)
@@ -8,12 +8,13 @@
                        inference = TRUE,
                        inference.strategy = "bootstrap",
                        ...) {
-                                        # type = "marketResidual", "excessReturn", "AMM", "None"
-  ## arguments to the model
-  extra.var <- list(...)
   
   if (type == "None" && !is.null(firm.returns)) {
     outputModel <- firm.returns
+    if (length(list(...)) != 0) {
+        warning(deparse("type"), " = ", deparse("None"),
+                " does not take extra arguments, ignoring them.")
+    }
   }
 
   if (is.levels == TRUE) {



More information about the Eventstudies-commits mailing list