similar to: debugging an S4 method

Displaying 20 results from an estimated 1000 matches similar to: "debugging an S4 method"

2005 Feb 22
2
estimate the parameter of exponential distribution, etc.
Given a numeric vector of observations, does R have any generic way to estimate the parameters of commonly used distributions (exponential, gamma, etc.) without numerically optimizing the likelihood function? Thanks, David _______________________________________ David R. Bickel http://davidbickel.com Research Scientist Pioneer Hi-Bred International Bioinformatics & Exploratory Research 7250
2004 Aug 31
2
enter browser on error
Is there a way I can get R to automatically enter the browser inside a user-defined function on the generation of an error? Specifically, I'm trying to debug this: Error in as.double.default(sapply(lis, FUN)) : (list) object cannot be coerced to double In addition: There were 38 warnings (use warnings() to see them) > traceback() 8: as.double.default(sapply(lis, FUN)) 7:
2006 Sep 29
2
GLM information matrix
Is there a function that provides the Fisher information matrix for a generalized linear model? I do not see how to access the off-diagonal matrix elements of the value returned by glm. (I'm particularly interested in logistic regression.) If not, what is a good way to use R to compute Hessians or other partial derivatives of log likelihoods? I would appreciate any guidance. David
2005 Dec 23
2
convolution of the double exponential distribution
Is there any R function that computes the convolution of the double exponential distribution? If not, is there a good way to integrate ((q+x)^n)*exp(-2x) over x from 0 to Inf for any value of q and for any positive integer n? I need to perform the integration within a function with q and n as arguments. The function integrate() is giving me this message: "evaluation of function gave a
2004 Aug 02
2
random seed puzzle
After reading the help page on set.seed, I am unsure about how to solve the following problem. I need to call function f a thousand times. The list of values returned by f, should be as random as possible. f calls g twice: f <- function(){g1 <- g(1); g2 <- g(2); c(g1; g2)} The function g in turn calls sample and returns a number, but also depends on its argument, so, starting from the
2004 Jun 04
1
running R command in the background
Is there a way to call an R function to work in the background within the same R session? What I have in mind is the equivalent of adding '&' at the end of a UNIX command, so that R can process an intensive command while I execute other R commands. I want to do this in the same R session, rather than with multiple calls to R, so that all my modified objects will stay in the same
2004 Jul 22
1
viewing Postscript file
Is there any R function that can display a Postscript file that is already in the working directory? For example, if 'graph.ps' is such a file, I'd like to type something like this: > plot.postscript.file(file = 'graph.ps') If no such function exists, I'd be interested in a way to use existing R functions to do this under UNIX or Windows, preferably without a system
2004 May 12
4
non-interactive call to R (running an R package as a stand-alone application)
Is there a way I can have R automatically execute the commands in a source file without ever having to use R interactively? If so, what arguments should I pass to the UNIX call to R? I need to do this to run several R jobs in parallel. An alternative may be to have R and an R package behave as a stand-alone application that can be called from the UNIX command line. Is there any documentation on
2004 Jun 14
4
interrupt in Linux
Does anyone know how to interrupt R in RedHat? Neither control-c nor Esc is working. What I don't want to do is close the window or kill the entire R process. Thanks, David This communication is for use by the intended recipient and ...{{dropped}}
2005 Nov 10
1
order statistics / sample quantiles
Are there any R functions or packages that can compute distributions, expectations, or quantiles of order statistics (or sample quantiles or extreme values) for a given distribution such as a normal distribution? Both exact and asymptotic calculations are of interest. I am already aware of the 'quantile' function of 'stats'. David _______________________________________ David R.
2004 May 05
1
Installation on Windows XP
R never gave me any serious problems until I tried to use it on Windows XP. I had 1.8.1 installed and working successfully for a few weeks. This morning when I launched it, I received this error message: "R for Windows GUI front-end has encountered a problem and needs to close. We are sorry for the inconvenience." I downloaded 1.9.0 and installed it, but when I launch it, I get this
2010 Jul 14
3
Mathematica and R
What are some effective ways to leverage the strengths of R and Mathematica for the analysis of a single data set? More specifically, are there any functions that can assist with any of the following? 1. Calling an R function from Mathematica. 2. Calling a Mathematica function from R. 3. Using XML or another reliable data format to pass vectors, matrices, and/or lists from one environment to
2002 Nov 21
4
Mixing text and graphics in PDF
Is there an easy way to "sink" text output to a pdf file using the pdf() device? Here's an email that describes setting up empty graphics plots and then using the "text" command to put text on page: http://www.r-project.org/nocvs/mail/r-help/2002/5598.html I'm just looking for something a little more polished -- automatic page breaks, line wrapping, etc. Kevin
2002 Sep 09
1
No reorder.factor in R
I was using R 1.5.1 today with an old script from S-Plus and discovered that R does not have reorder.factor. It's a very simple function, but very handy for re-arranging factors in lattice graphics (among other places). Would it make sense to add this function to the base code in order to increase compatability with S-Plus and add additional functionality? reorder.factor <-
2011 Feb 04
3
shade between two curves
Is there a function that can shade the region between two arbitrary curves? For example, how can I fill in the area between these two plotted curves? > x <- 1:10 > y <- x + rnorm(10) > z <- x + 10 + rnorm(10) > plot(x, y, type = "l", ylim = c(0,20)) > lines(x, z) I would appreciate any help. David
2002 Jun 10
2
library() with v. 1.5.0 for Mac OS X Carbon
I am having trouble with the library function of R Version 1.5.0 for Mac OS X Carbon when I try to load libraries that did not come with the R installation. For example, I put the Biobase library from bioconductor.org in the 'library' folder. R cannot find it, even though it can find the pre-installed libraries: > library() # this lists standard libraries such as 'boot',
2010 Jul 08
2
package installation for Windows 7
Neither biocLite nor the GUI menus can install packages on my system. Here is relevant output: > version _ platform i386-pc-mingw32 arch i386 os mingw32 system i386, mingw32 status major 2 minor 11.1 year 2010 month 05 day 31 svn rev 52157 language R version.string R version 2.11.1 (2010-05-31) > source("http://bioconductor.org/biocLite.R") BioC_mirror =
2003 Aug 21
2
automatic logging of commands
Is there an R function that automatically writes all input and output to a file? I would at least like it to log all the commands I enter, and to preferably also write the standard output to the file as well as to the screen. (The ideal would be to write the input to one file and both the input and output to another file.) I tried R2HTML for this, but I could not get it to work consistently. I am
2007 Dec 10
3
3-D plot of likelihood
Could anyone recommend a package for visualizing a likelihood function of two scalar parameters? I would prefer a three-dimensional plot similar to the kind Mathematica is known for, perhaps generated by a package not specific to likelihood. David ______________________________ David R. Bickel Ottawa Institute of Systems Biology BMI Dept., University of Ottawa http://www.oisb.ca/members.htm
2008 Jan 09
3
likelihood from test result
Is there any automatic mechanism for extracting a likelihood or test statistic distribution (PDF or CDF) from an object of class "htest" or from another object of a general class encoding a hypothesis test result? I would like to have a function that takes "x", an object of class "htest", as its only argument and that returns the likelihood or test statistic