Displaying 20 results from an estimated 400 matches similar to: "Catching warning message(stdout) from C"
2010 Dec 06
1
lattice: strip panel function question
Dear list,
If have some repeated measurement data which looks something like:
time <- rep(1:5 , each=2*4)
groups <- rep(c("Case", "Control"), each=4)
subjects <- factor(rep(1:(2*4), 5))
responses <- time + rnorm(5*2*4) + as.integer(factor(groups))
data <- data.frame(responses, time, groups, subjects)
Now I want to plot each subject in a separate panel:
2016 Mar 10
3
rmultinom.c error probability not sum to 1
Hi all,
I should have given a better explanation of my problem. Here it is.
I extracted from my code the bit that gives the error. Place this in a file called test.c
#include <math.h>
#include <R.h>
#include <Rmath.h>
#include <float.h>
#include <R_ext/Print.h>
int main(){
double prob[3] = {0.0, 0.0, 0.0};
double prob_tot = 0.;
prob[0] = 0.3*dnorm(2, 0,
2007 Aug 28
3
Forcing coefficients in lm object
Dear all,
I would like to use predict.lm() with an existing lm object but with new arbitrary coefficients. I modify 'fit$coef' (see example below) "by hand" but the actual model in 'fit' used for prediction does not seem to be altered (although fit$coef is!).
Can anyone please help me do this properly?
Thanks in advance,
J?r?mie
> dat <-
2016 Mar 10
2
rmultinom.c error probability not sum to 1
Dear all,
I have a questions regarding using the c function rmultinom.c.
I got the following error message "rbinom: probability sum should be 1, but is 0.999264"
Which is thrown by:
if(fabs((double)(p_tot - 1.)) > 1e-7)
MATHLIB_ERROR(_("rbinom: probability sum should be 1, but is %g"),
(double) p_tot);
I understand my probabilities do not sum to one close enough. I
2016 Mar 10
0
rmultinom.c error probability not sum to 1
> On 10 Mar 2016, at 21:25 , M.van_Iterson at lumc.nl wrote:
>
> Hi all,
>
> I should have given a better explanation of my problem. Here it is.
>
> I extracted from my code the bit that gives the error. Place this in a file called test.c
Aha. Missing info #1, C not R...
>
> #include <math.h>
> #include <R.h>
> #include <Rmath.h>
>
2016 Mar 10
0
rmultinom.c error probability not sum to 1
On 10 Mar 2016, at 12:47 , M.van_Iterson at lumc.nl wrote:
> Dear all,
>
> I have a questions regarding using the c function rmultinom.c.
>
> I got the following error message "rbinom: probability sum should be 1, but is 0.999264"
>
> Which is thrown by:
>
> if(fabs((double)(p_tot - 1.)) > 1e-7)
> MATHLIB_ERROR(_("rbinom: probability sum should
2002 Mar 14
1
"evaluating expression 0" bug in R-1.4.1 (PR#1385)
Full_Name: Edward J. Neafsey
Version: 1.4.1
OS: linux
Submission from: (NULL) (147.126.192.93)
R-1.4.1 failed to finish compiling building package `methods', as seen in
output from make below.
============================================================================
Make output:
../../../library/methods/man/methods.Rd is unchanged
make[4]: Entering directory
2002 Oct 14
1
Question: concatenating lists
Dear R users,
I have the following problem. I have a number of lists with identical
structure. Each component is a vector, matrix or array, but components of
different lists may be of different size. How do I combine the lists to get
a new list such that each component of this list contains the components of
the individual lists?
An example may explain most clearly what I need.
Suppose I have
2004 Oct 14
3
is.vector() gives error (PR#7288)
Full_Name: Jelle Goeman
Version: 2.0.0
OS: windows
Submission from: (NULL) (145.88.209.33)
I get a strange error:
> is.vector(1:10)
Error: recursive default argument reference
What's recursive about is.vector?
Kind regards,
Jelle Goeman
My R:
platform i386-pc-mingw32
arch i386
os mingw32
system i386, mingw32
status
major 2
2004 Jun 28
2
Problem with hasArg and the ... argument (PR#7027)
Full_Name: Jelle Goeman
Version: 1.9.0
OS: mingw32, windows 2000
Submission from: (NULL) (145.88.209.33)
Hi Everyone,
I get very strange results using the function hasArg with the ... function
argument. In my own function:
> gt <- globaltest(X,Y)
> sampling(gt)
works fine, but
> sampling(globaltest(X,Y))
results in:
Error in eval(expr, envir, enclos) : "missing"
2003 Sep 16
0
With the recent OS changes (windows 2000) necessitated by (PR#4188)
This is not a bug. It indicates that *you* don't have direct internet
access. There is an item in the rw-FAQ about this.
Please do not use R-bugs to report problems in your own environment, nor to
ask questions (especially those covered in FAQs).
On Tue, 16 Sep 2003 ggruene@lumc.edu wrote:
> With the recent OS changes (windows 2000) necessitated by various worms, etc, I have now been
2013 Apr 03
1
R-package preparation --as-cran behaving unexpectedly
Dear all,
I am trying to submit an R-package to CRAN. In preparation I do run
R_INSTALL_TAR=/bin/tar R CMD check --as-cran parallelize.dynamic_0.9.tar.gz
and the command finishes without warnings or errors. As a final output I get
NOTE: There was 1 note.
See
?.../Rpackages/parallelize.dynamic/parallelize.dynamic.Rcheck/00check.log?
for details.
The file contains the standard output of the
2003 Mar 06
1
Some bugs in Rcmd check ? (PR#2608)
Hello!
I have some problems using Rcmd, bacause I get errors I do not understand. I
will write down what I did. Perhaps you can help me?
I have a small would-be package called "globaltest", containing only the
files
DESCRIPTION
INDEX
R/globaltest.R
man/globaltest.Rd
I say:
C:\>Rcmd check C:/Goeman/globaltest
In the output it first complains that 'sh', 'make',
2003 Sep 16
1
With the recent OS changes (windows 2000) necessitated by (PR#4187)
With the recent OS changes (windows 2000) necessitated by various worms, etc, I have now been receiving this error message when I run update and I am not sure how I can correct.
>update.packages()
>trying URL `http://cran.r-project.org/bin/windows/contrib/PACKAGES'
Error in download.file(url = paste(contriburl, "PACKAGES", sep = "/"), :
cannot open: HTTP
2007 Apr 05
1
issue with pdf(paper="a4") in 2.5.0 alpha
In the latest windows binary (2007-04-03 r41023) pdf() with an argument paper="a4" gives an error, this was still ok in (2007-03-18 r40854)
Jan Oosting
> pdf("test.pdf",paper="a4")
Error in pdf("test.pdf", paper = "a4") : invalid paper type 'a4' (pdf)
> sessionInfo()
R version 2.5.0 alpha (2007-04-03 r41023)
i386-pc-mingw32
2012 Jan 13
2
function to replace values doesn't work on vectors
I've got a numeric vector with values ranging from 1 to 5, I would like to
catagorize these values like this:
1 becomes catagory 1
3 becomes catagory 3
And everything else in catagory 2. The simple function I wrote beneath works
for single numeric data, but for some reason I am unable to feed it vectors.
Any help would be appreciated, as I'm fairly new to R.
--
View this message in
2007 Feb 21
1
avoiding a needless function evaluation in optimize() (PR#9523)
Full_Name: Jelle Goeman
Version: 2.4.0
OS: windows XP
Submission from: (NULL) (145.88.209.33)
Hi,
I like to use optimize() to optimize functions whose evaluation is costly in
terms of computation time. The Brent algorithm which is implemented in optimize
was designed to optimize a function with as few function evaluations as
possible. Therefore it bothers me that optimize() always evaluates
2012 Jun 12
2
Error in sort(abs(diff(genomdat)))[1:n.keep] : only 0's may be mixed with negative subscripts
Hello everyone,
I`m trying to normalize and analize an illumina SNP array.
But when i`m trying to segmentate i`m getting an error:
Error in sort(abs(diff(genomdat)))[1:n.keep] :
only 0's may be mixed with negative subscripts.
I`ve tried everything to fix this but the error still occours.
Can anybody give me a tip?
Thanks in advance!
--
View this message in context:
2013 Jan 26
1
Attempting to confirm a program i wrote in C (normalize 2 datasets, transform into histogram, transform into CDF, perform KS test)
I have written a program in C that two xy datasets, aligns these 2 datasets
based on shared features, transforms them into equal sized histograms,
transforms the histograms into cumulative distribution functions (via GSL)
and finally performs a KS_test.
I am wanting to validate my program's results and figure'd i would use R but
i am kinda stuck at ithe histograms (I have 2 histogram
2009 Oct 14
1
different L2 regularization behavior between lrm, glmnet, and penalized?
The following R code using different packages gives the same results for a
simple logistic regression without regularization, but different results
with regularization. This may just be a matter of different scaling of the
regularization parameters, but if anyone familiar with these packages has
insight into why the results differ, I'd appreciate hearing about it. I'm
new to