Displaying 20 results from an estimated 10000 matches similar to: "glm binomial with zero proportions"
2006 Jul 02
4
Test for argument in ...
Hello!
Say I have a function foo1, which has argument ... to pass various
arguments to foo2 i.e.
foo1 <- function(x, ...)
{
foo2(x, ...)
}
Say that foo2 accepts argument arg1 and I would like to do the following:
- if foo1 is called as foo1(x) then I would like to assign some value to
arg1 inside foo1 before calling foo2
arg1 <- "some value"
foo2(x, arg1=arg1)
- if foo1 is
2005 Jun 08
6
Random seed problem in MCMC coupling of chains
Hello!
I am performing coupling of chains in MCMC and I need the same value
of seed for two chains. I will show demo of what I want:
R code, which might show my example is:
niter <- 3
nchain <- 2
tmpSeed <- 123
for (i in 1:niter) { # iterations
for (j in 1:nchain) { # chains
set.seed(tmpSeed)
a <- runif(1)
cat("iter:", i, "chain:", j,
2005 May 08
2
Extract just some fields from XML
Hello!
I am trying to get specific fields from an XML document and I am totally
puzzled. I hope someone can help me.
# URL
URL<-"http://eutils.ncbi.nlm.nih.gov/entrez/eutils/efetch.fcgi?db=pubmed&id=11877539,11822933,11871444&retmode=xml&rettype=citation"
# download a XML file
tmp <- xmlTreeParse(URL, isURL = TRUE)
tmp <- xmlRoot(tmp)
Now I want to extract only
2006 Feb 10
8
Fitdistr and MLE for parameter lambda of Poisson distribution
Hello!
I would like to get MLE for parameter lambda of Poisson distribution. I
can use fitdistr() for this. After looking a bit into the code of this
function I can see that value for lambda and its standard error is
estimated via
estimate <- mean(x)
sds <- sqrt(estimate/n)
Is this MLE? With my poor math/stat knowledge I thought that MLE for
Poisson parameter is (in mixture of LaTeX
2006 Feb 14
3
A concrete type I/III Sum of square problem
Hi R-help members,
I have read a lot in the Archive about the "Type I" vs "Type III" sum
of square. I think I have read confusing post so
I want to have a clear idea of the problem.
Here is an example.
I have 3 groups of subjects of unequal sample size (G1 (n=7), G2
(n=7), G3 (n=4)).
for Each subject I have 4 measures corresponding to the crossing of
2 factor (A & B)
2005 Mar 25
4
Gmail invitation
Hello R users!
I just found out that I have 49 invitations for Gmail (gmail.google.com).
I have been using it now for a while and is really nice. Don't forget
1 GB for free.
I will invite those who respond to this mail by FIFO.
--
Lep pozdrav / With regards,
Gregor Gorjanc
------------------------------------------------------------------------
University of Ljubljana
Biotechnical
2006 Aug 01
1
Global setting for na.rm=TRUE
Hello!
Is it possible to set na.rm=TRUE in a global way? I'am constantly
forgeting on this when performing analyses. I agree that one should
be carefull with this when developing some code, but not necesarilly
so in data analysis.
Lep pozdrav / With regards,
Gregor Gorjanc
----------------------------------------------------------------------
University of Ljubljana PhD student
2005 Feb 22
6
Run Sweave and LaTeX directly from command line
Hello!
Those of you, who use Sweave a lot, will probably find my shell script
usable. You can get it at:
http://www.bfro.uni-lj.si/MR/ggorjan/programs/shell/Sweave.sh
No warranty, however don't hesitate to contact me if you find an error or
have a patch!
--
Lep pozdrav / With regards,
Gregor GORJANC
---------------------------------------------------------------
University of
2006 Apr 29
3
Making R talk to Win/OpenBUGS in Linux (again)
I'm back!
I've just learned that, on a fully updated Fedora Core Linux5 sytem,
the working solution to access Winbugs under wine via the R package
"rbugs" no longer works. Here was my last post on this topic (with
the formerly working solution) from January.
http://finzi.psych.upenn.edu/R/Rhelp02a/archive/68497.html
Currently, what happens is that WinBUGS starts up, but just
2006 Mar 20
2
levels for list and data.frame
Hello!
Does R core find the following pacth usefull - I created methods for
levels for list and data.frame, which can be usefull to get a list of
levels for entries in a list or columns in a data.frame. Patch is
attached and shown bellow example
# Example
> tmp <- list()
> tmp$a <- factor(letters[1:10])
> tmp$b <- factor(letters[5:14])
> tmp$c <- 1:10
> tmp1 <-
2006 Aug 07
2
Constrain coefs. in linear model to sum to 0
Hello!
I would like to use constrain to sum coeficients of a factor to 0 instead
of classical corner contraint i.e. I would like to fit a model like
lm(y ~ 1 + effectA + effectB)
and say get parameters
intercept
effectA_1
effectA_2
effectB_1
effectB_2
effectB_3
where effectA_1 represents deviation of level A_1 from intercept and
sum(effectA_1, effectA_2) = 0 and the same for factor B.
Is
2005 Mar 27
3
F90
Hello!
Has anyone successfully compiled F90 sources in R-package? I found the
same question on r-devel list from 2002 and I wonder if there is any
progress. I heard that g95 and gfortran can be usable.
And one more thing. I have a program written in F90 and lets suppose that
compiler is not a problem. I've read manual 'Writing R Extensions' and
successfully loaded one F77 subroutine
2005 Mar 27
3
F90
Hello!
Has anyone successfully compiled F90 sources in R-package? I found the
same question on r-devel list from 2002 and I wonder if there is any
progress. I heard that g95 and gfortran can be usable.
And one more thing. I have a program written in F90 and lets suppose that
compiler is not a problem. I've read manual 'Writing R Extensions' and
successfully loaded one F77 subroutine
2005 Feb 23
4
Sweave and \input or \include LaTeX commands
Hello!
I was just wondering if Sweave can work with \input or \include
LaTeX commands. So, is it aware of such a possible hierarchy in
documents. I would test that, but I don't have such a report
available at the moment.
I thought of that when I was writting shell script for Sweave
from command line and I have solved that part there.
--
Lep pozdrav / With regards,
Gregor GORJANC
2006 May 20
3
How long is winepath available?
Hello!
Can someone provide me an estimate or relevant source of information on
how long is command winepath available or from wich version of wine? I
would need this as I work on some R[1] package R2WinBUGS[2] that calls
a Windows program WinBUGS[3] and that program needs windows paths.
Currently winepath or parsing of .wine/config is used and I wonder if I
can remove fiddling with .wine/.config.
2005 Apr 24
4
Upgrading R
Hello!
New version of R has came out and I would like to thank to all developers
on this matter. So I should probably upgrade. Fine and no problem. For
windows I just grab the latest precompiled binnaries and install them. Then
I see a report on a bug, which is or will be fixed in pacthed version. So
I need to get binnaries from patched build and install them, right?
How often do you people
2005 Apr 24
4
Upgrading R
Hello!
New version of R has came out and I would like to thank to all developers
on this matter. So I should probably upgrade. Fine and no problem. For
windows I just grab the latest precompiled binnaries and install them. Then
I see a report on a bug, which is or will be fixed in pacthed version. So
I need to get binnaries from patched build and install them, right?
How often do you people
2006 Oct 12
1
Problems with package foreign (r-cran-foreign)
On 12 October 2006 at 13:02, Gregor Gorjanc wrote:
| Hello!
|
| I encounter the following problem when I try to load package foreign
|
| library(foreign)
| Error in dyn.load(x, as.logical(local), as.logical(now)) :
| unable to load shared library '/usr/lib/R/library/foreign/libs/foreign.so':
| /usr/lib/R/library/foreign/libs/foreign.so: undefined symbol:
| Rf_allocString
| Error:
2006 Jan 16
3
Current state of support for BUGS access for Linux users?
Greetings:
I'm going to encourage some students to try Bayesian ideas for
hierarchical models.
I want to run the WinBUGS and R examples in Tony Lancaster's An
Introduction to Modern Bayesian Econometrics. That features MS
Windows and "bugs" from R2WinBUGS.
Today, I want to ask how people are doing this in Linux? I have found
a plethora of possibilities, some of which are not
2006 Mar 17
3
Collapsing levels of a factor
> x <- factor(1:3, labels = c("b" , "f", "minus"))
> x
[1] b f minus
Levels: b f minus
I want to change all "minus" to "b". I know that the simplest way to do this is
> levels(x) <- c("b", "f", "b")
and also that
> x[x == "minus"] <- "b"
> x <- factor(x)