Re: [R] Problem with long number (from character to numeric class)

2011-02-09 Thread Ben Bolker
for precision) for alternatives for extended precision calculations. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide

Re: [R] Error running LME model

2011-02-09 Thread Ben Bolker
response variable? In general, lme questions should go to the r-sig-mixed-models mailing list. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org

Re: [R] Unbalanced Mixed Linear Models With Nested Stratum

2011-02-08 Thread Ben Bolker
-requisites (minqa and MatrixModels) install fine. So I guess we'll have to find a way to make it work on 2.12.1 - the version I'm using. GenStat managed to analyse the same data just fine, so it's not a problem with the data. Can you send data? Crashing R is by definition a bug ... Ben

Re: [R] Use glm coefficients for other datasets

2011-02-08 Thread Ben Bolker
maxsilva mmsilva3 at uc.cl writes: I generated a glm logit model using a sample of a bigger set, and now I want to test the model with the bigger set. How can I do this? predict makes predictions only for a number of rows equal to the sample used. The question is, how can I use the

Re: [R] Fitting a model with an offset in bigglm

2011-02-08 Thread Ben Bolker
people like me doing the hacking ... Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained

Re: [R] Error in example Glm rms package

2011-02-08 Thread Ben Bolker
are starting from a clean session; (2) perhaps, if you're up to it, using traceback() and/or options(error=recover) to try to track the problem a bit farther; (3) contacting the package maintainer ... Ben Bolker __ R-help@r-project.org mailing list

Re: [R] Use glm coefficients for other datasets

2011-02-08 Thread Ben Bolker
maxsilva mmsilva3 at uc.cl writes: Thank you for your answer. But I still have the problem; for example, if i have data for 10 months, estimate the parameters of my logit model using 10 months of data, and then use predictions-predict(model,data=1monthonly,family = binomial(link =

Re: [R] intervals {nlme} lower CI greater than upper CI !!!????

2011-02-08 Thread Ben Bolker
Federico Bonofiglio bonoricus at gmail.com writes: You're confused by the formatting differences betwen columns. The first column uses 'standard' notation, the second and third use 'scientific' notation -- see comments inline.

Re: [R] [Rd] print(...,digits=2) behavior

2011-02-07 Thread Ben Bolker
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11-02-07 03:56 AM, Martin Maechler wrote: Ben Bolker bbol...@gmail.com on Sat, 5 Feb 2011 15:58:09 -0500 writes: A bug was recently posted to the R bug database (which probably would better have been posted as a query here

Re: [R] question mle again

2011-02-07 Thread Ben Bolker
Antje Niederlein niederlein-rstat at yahoo.de writes: A few day ago, I was looking for an answer to my question but didn't get one. Anybody who can help now? Hello, I tried to use mle to fit a distribution(zero-inflated negbin for count data). My call is very simple: I will point

Re: [R] Unbalanced Mixed Linear Models With Nested Stratum

2011-02-07 Thread Ben Bolker
JaFF el.romaro at gmail.com writes: Hi folks, I have a dataset from a trial measuring the subjects' pupils. There are many measurements, all of which must be analysed in a similar fashion; so if I get the analysis right for one of them, I've got them all. For simplicity, let us call

Re: [R] Confidence interval based on MLE

2011-02-06 Thread Ben Bolker
Jinsong Zhao jszhao at yeah.net writes: Hi there, I have fitted a sample (with size 20) to a normal and/or logistic distribution using fitdistr() in MASS or fitdist() in fitdistrplus package. It's easy to get the parameter estimates. Now, I hope to report the confidence interval for

Re: [R] function optimization

2011-02-06 Thread Ben Bolker
questions. good luck, Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained

Re: [R] Why my package is not being generated?

2011-02-03 Thread Ben Bolker
Cristiano Strieder cstrieder at gmail.com writes: Hi all, I have commited a new release of my package and waited for more than one day. After that install.packages(tests,repos=http://r-forge.r-projet.org;) still returns package 'tests' is not available. I have done the local build

Re: [R] substring and paste character with a for loop

2011-02-03 Thread Ben Bolker
Chris82 rubenbauar at gmx.de writes: Hello R users, I have a little problem with a for loop. Below there is an simple example of my problem. I want to delet the commas in the character string. Fore this reason I create a for loop to unpick the string and rebuild him without the

Re: [R] error in density plot

2011-02-03 Thread Ben Bolker
On 02/02/2011 09:29 AM, David Winsemius wrote: On Feb 2, 2011, at 8:22 AM, Ben Bolker wrote: Ramya ramya.victory at gmail.com writes: I have the code for the density plot j - 8 plot(density(diff_in_sample[,1]), main = list.files()[j]) for(i in 1:25){ lines(density(diff_in_sample[,i

Re: [R] error in density plot

2011-02-03 Thread Ben Bolker
My concern was that it was outside the density function and I thought the density function would throw an error before it passed anything to na.omit(). plot(na.omit(density(c(1,1,1,1,1,NA,4,4,4,4))) ) Error in density.default(c(1, 1, 1, 1, 1, NA, 4, 4, 4, 4)) : 'x' contains missing

Re: [R] error in density plot

2011-02-02 Thread Ben Bolker
Ramya ramya.victory at gmail.com writes: I have the code for the density plot j - 8 plot(density(diff_in_sample[,1]), main = list.files()[j]) for(i in 1:25){ lines(density(diff_in_sample[,i])) } This gives me an error Error in density.default(diff_in_sample[, i]) : 'x' contains

Re: [R] better way to iterate matrix multiplication?

2011-02-01 Thread Ben Bolker
Eik Vettorazzi E.Vettorazzi at uke.uni-hamburg.de writes: if you have a homogeneous mc (= a constant transition matrix), your state at time 10 is given by (chapman-kolmogorov) p10=p0 %*% tm^(10) so you need a matrix power function. There are matrix exponential functions in the Matrix and

Re: [R] test statistic in anova.glm when quasi family is used

2011-01-31 Thread Ben Bolker
are Venables and Ripley (i.e. MASS) and Crawley's Statistical Data Analysis book. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html

Re: [R] rgl: draw multiple ellipsoids

2011-01-31 Thread Ben Bolker
baptiste auguie baptiste.auguie at googlemail.com writes: Dear list, I'm trying to visualise some ellipsoidal shapes in 3D. Their position, axes, and angular orientation can be arbitrary. I saw an ellipse3d function in rgl; however it is heavily oriented towards the statistical concept

Re: [R] package R2WinBUGS question; was: Multilevel

2011-01-29 Thread Ben Bolker
Uwe Ligges ligges at statistik.tu-dortmund.de writes: On 29.01.2011 15:06, martanair wrote: [snip] I write: radon.data- list (n, J, x, y, county) radon.inits- function (){ list (a=rnorm(J), b=rnorm(1), mu.a=rnorm(1), sigma.y=runif(1), sigma.a=runif(1)) }

Re: [R] Linear mixed model: question about t-values

2011-01-28 Thread Ben Bolker
Kostenko, Olga O.Kostenko at nioo.knaw.nl writes: I have a question about the output of linear mixed model fitted in R using nlme package. In particular, what are the t-values that are given in an output, how are they calculated and based on what test? I guess it cannot be a simple Student

Re: [R] Help with ape - read.GenBank()

2011-01-28 Thread Ben Bolker
James Meadow jfmeadow at gmail.com writes: Hi, I am trying to work with the ape package, and there is one thing I am struggling with. When calling the *read.GenBank()* function, I can get it to work with an object created like this: *x - c(AY395554,AY611035, ...)* *read.GenBank(x)*

Re: [R] Warning with mle

2011-01-27 Thread Ben Bolker
on the boundary, e.g. if the best estimate of your zero-inflation parameter is zero or very close to it. 4. Use the pscl package, which has reasonably robust and efficient built-in functions for fitting zero-inflated (and hurdle) models. good luck, Ben Bolker

Re: [R] Writing program for these

2011-01-27 Thread Ben Bolker
before posting.) One hint for the second question: ?rt good luck, Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide

Re: [R] Writing program for these

2011-01-27 Thread Ben Bolker
,trim=0.05) #or 0.1 I am not sure z-sort(x) #next use either y-z[-c(1:50,951:1000)] # We want the bottom 5% and top 5% so this corresponds to the elements that we are taking away. #or #y-z[-c(1:100,901:1000)] mean(y) -- From: Ben Bolker bbol

Re: [R] Help Derivate for Nonlinear Growth Models

2011-01-26 Thread Ben Bolker
it helps a lot. I would also suggest going to Google scholar and searching for 'nls growth curve Bates to find some papers that have used this approach. If you need to post again, please read the posting guide and show us how far you have managed to get on your own. good luck, Ben Bolker

Re: [R] Implementing step-wise linear regression

2011-01-24 Thread Ben Bolker
Tal Galili tal.galili at gmail.com writes: Hello Troy. A tiny question (without answering your question), why did you choose to do it this way instead of using ?step or ?stepAIC ? [snip snip] My questions are: Should I be using var.test to run the F-test to decide which

Re: [R] Linear mixed model: question about t-values

2011-01-24 Thread Ben Bolker
Kostenko, Olga O.Kostenko at nioo.knaw.nl writes: I have a question about the output of linear mixed model fitted in R using nlme package. In particular, what are the t-values that are given in an output, how are they calculated and based on what test? I guess it cannot be a simple Student

Re: [R] Ordering box plots

2011-01-23 Thread Ben Bolker
Stuart Luppescu slu at ccsr.uchicago.edu writes: I want box plots by group to display in order of increasing mean (or median) of each group but can't seem to figure it out and couldn't find anything on R-seek, either. ?reorder ... ? __

Re: [R] faster mvrnorm alternative

2011-01-22 Thread Ben Bolker
fantomas tomas.iesmantas at gmail.com writes: Hello, does anybody know another faster function for random multivariate normal variable simulation? I'm using mvrnorm, but as profiling shows, my algorithm spends approximately 50 % in executing mvrnorm function. Maybe some of you knows

Re: [R] MCMC object indexing

2011-01-20 Thread Ben Bolker
(20)) library(coda) m - mcmc(data=z) t(apply(m,2,quantile,c(0.025,0.975))) If that sort of thing doesn't work for you, please post an example of what doesn't work ... Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

Re: [R] Help with logistic model with random effects in R

2011-01-19 Thread Ben Bolker
suggest that you send follow-ups to r-sig-mixed-mod...@r-project.org and possibly take a look at http://glmm.wikidot.com/faq cheers Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting

Re: [R] Using anova() with glmmPQL()

2011-01-18 Thread Ben Bolker
Toby Marthews toby.marthews at ouce.ox.ac.uk writes: Dear R HELP, ABOUT glmmPQL and the anova command. Here is an example of a repeated-measures ANOVA focussing on the way starling masses vary according to (i) roost situation and (ii) time (two time points only). [snip]

Re: [R] GLMM with lme4 and octopus behaviour

2011-01-11 Thread Ben Bolker
Samaritan d.harliwich at gmail.com writes: [snip] You might want to ask follow-up questions on the R-sig-mixed-models list At the most basic level, I'm testing the effect of sleep deprivation on various behaviours (e.g. amount of time spent awake, amount of time spend expressing

Re: [R] Anova with repeated measures for unbalanced design

2011-01-08 Thread Ben Bolker
Frodo Jedi frodo.jedi at yahoo.com writes: Dear all, I need an help because I am really not able to find over internet a good example in R to analyze an unbalanced table with Anova with repeated measures. For unbalanced table I mean that the questions are not answered all by the same

Re: [R] Problems with glht function for lme object

2011-01-07 Thread Ben Bolker
anord andreas.nord at zooekol.lu.se writes: Dear all, I'm trying to make multiple comparisons for an lme-object. The data is for an experiment on parental work load in birds, in which adults at different sites were induced to work at one of three levels ('treat'; H, M, L). The

Re: [R] Different LLRs on multinomial logit models in R and SPSS

2011-01-06 Thread Ben Bolker
[1] 5.2245 Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] How to save graphs out of ACF ?

2011-01-05 Thread Ben Bolker
Mihai.Mirauta at bafin.de writes: Hi, I want to save the autocorrelation plots resulting out of ACF (acf(ts)), not just by using the Save as command in the R Gui but using some sort of code, which allows me to chose the format and the path. Thank you, Mihai for example: a -

Re: [R] How to 'explode' a matrix

2011-01-05 Thread Ben Bolker
)) cheers Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] how to keep keep matching column in output of merge

2011-01-04 Thread Ben Bolker
Nevil Amos nevil.amos at gmail.com writes: How do I keep the linking column[s] in a merge()? I need to use the values again in a further merge. simple reproducible example please? (e.g. make up a couple of 4-row datasets that show what you want, what you are trying, and what you are

Re: [R] Cost-benefit/value for money analysis

2011-01-04 Thread Ben Bolker
Graham Smith myotistwo at gmail.com writes: I assume this has a proper name, but I don't know what it is and wondered if anyone knew of a package that might do the following, or something similar. As an example, assume I have borrowed and read 10 books on R , and I have subjectively

Re: [R] using quot; plotquot; with time series object - quot; axes = FALSEquot; option does not appear to work

2011-01-03 Thread Ben Bolker
of arguments to the function, and the default was supposed to be TRUE. Because axes *is* in the explicit list of arguments, this overrides it. I would contact the maintainer [maintainer(xts)] and ask if this is a bug. cheers Ben Bolker __ R-help@r

Re: [R] Greetings. I have a question with mixed beta regr ession model in nlme.

2011-01-03 Thread Ben Bolker
luck Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] changing method of estimation in GLM

2011-01-02 Thread Ben Bolker
ATANU ata.sonu at gmail.com writes: can anyone tell me how can i control the method of estimation (i.e. scoring method or Newton raphson method) in glm and compute deviance function ? I don't think you can; you would have to write your own, although you can take advantage of the framework

Re: [R] Please, need help with a plot

2011-01-02 Thread Ben Bolker
Victor F Seabra vseabra at uol.com.br writes: Please, I wonder if someone knows how to add the less than or equal to symbol in the plot generated by the code below: var1-c('age = 3','age = 7','age = 10','age = 11','age = 20','age = 25','age = 30','age = 45','age = 50','age

Re: [R] Retrieving Factors with Levels Ordered

2011-01-01 Thread Ben Bolker
Berwin A Turlach berwin at maths.uwa.edu.au writes: G'day H.T. On Sat, 1 Jan 2011 00:41:10 -0500 (EST) H. T. Reynolds htr at udel.edu wrote: When I create a factor with labels in the order I want, write the data as a text file, and then retrieve them, the factor levels are no

Re: [R] problem with postscript command

2011-01-01 Thread Ben Bolker
)? -- Reread the detailed answers you got previously that distinguish the difference between how the character is stored within R and how it is printed on the console. good luck Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch

Re: [R] Example in quot; Applied Spatial Analysis with Rquot; giving error

2011-01-01 Thread Ben Bolker
markdx mrkdennehy at gmail.com writes: Example from page 29, Chapter 2.3 from Applied Spatial Analysis with R I am new to R...just trying to replicate the example from the book. m - matrix(c(0,0,1,1), ncol = 2, dimnames = list(NULL, + c (min, max))) Error in +c(min, max) : invalid

Re: [R] Sweave for quot;bigquot; data analysis

2010-12-31 Thread Ben Bolker
Duncan Murdoch murdoch.duncan at gmail.com writes: As others have said, there are packages that provide caching. I haven't used them, because I like to keep my projects as self-contained as possible: adding a dependency on one of those packages is undesirable[1]. What I do in the case

Re: [R] logistic regression or not?

2010-12-21 Thread Ben Bolker
array chip arrayprofile at yahoo.com writes: [snip] I can think of analyzing this data using glm() with the attached dataset: test-read.table('test.txt',sep='\t') fit-glm(cbind(positive,total-positive)~treatment,test,family=binomial) summary(fit) anova(fit, test='Chisq') First, is this

Re: [R] Coding a new variable based on criteria in a dataset

2010-12-21 Thread Ben Bolker
RaoulD raoul.t.dsouza at gmail.com writes: Hi, I'm a bit stuck and need some help with R code to code a variable F_R based on a combination of conditions. The first condition would code F_R as F and would be based on the min(Date) and Min(Time) for each combination of UniqueID

Re: [R] logistic regression or not?

2010-12-21 Thread Ben Bolker
. *From:* Ben Bolker bbol...@gmail.com *To:* r-h...@stat.math.ethz.ch *Sent:* Tue, December 21, 2010 5:08:34 AM *Subject:* Re: [R] logistic regression or not? array chip arrayprofile at yahoo.com http://yahoo.com/ writes: [snip] I can think of analyzing

Re: [R] transposing panel data

2010-12-20 Thread Ben Bolker
functions in the reshape (or reshape2) packages (reshape2 may be faster). It may take a bit of work to get the syntax right (try it out on a small subset of your data). Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

Re: [R] R.matlab memory use

2010-12-20 Thread Ben Bolker
). Thanks, Stefano On Sun, Dec 19, 2010 at 10:54 PM, Ben Bolker bbolker at gmail.com wrote: Stefano Ghirlanda dr.ghirlanda at gmail.com writes: I am trying to load into R a MATLAB format file (actually, as saved by octave). The file is about 300kB but R complains with a memory allocation

Re: [R] R.matlab memory use

2010-12-19 Thread Ben Bolker
Stefano Ghirlanda dr.ghirlanda at gmail.com writes: I am trying to load into R a MATLAB format file (actually, as saved by octave). The file is about 300kB but R complains with a memory allocation error: library(Rcompression) library(R.matlab) Loading required package: R.oo Loading

Re: [R] dotchart for matrix data

2010-12-18 Thread Ben Bolker
David Winsemius dwinsemius at comcast.net writes: On Dec 18, 2010, at 7:01 AM, e-letter wrote: Readers, I am trying to use the function dotchart. The data is: testdot category values1 values2 values3 values4 1a 10 27 56 709 2b 4

Re: [R] Solution to differential equation

2010-12-17 Thread Ben Bolker
Ben Bolker bbolker at gmail.com writes: Mike Marchywka marchywka at hotmail.com writes: [snip] The gsl package has this function, apparently -- it agrees with Mathematica/Wolfram Alpha's Hypergeometric2F1 for a single set of inputs (2,3,4,0.5), although apparently the algorithm

Re: [R] Integrate two function in R

2010-12-16 Thread Ben Bolker
Alaios alaios at yahoo.com writes: Hello I have two function in R like g(x)=2x-3 and s(x)=5x^2+2 and I want to find the integrafl of the g(x)*s(x) inside the interval of [a,b] Analytically or numerically? It sounds like you want the answer analytically, in which case R can't do

Re: [R] extracting IDs from topGO results

2010-12-16 Thread Ben Bolker
is that you want to answer this question on the Bioconductor mailing list instead ... Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html

Re: [R] Integrate two function in R

2010-12-16 Thread Ben Bolker
Ben Bolker bbolker at gmail.com writes: Analytically or numerically? It sounds like you want the answer analytically, in which case R can't do it, but it is an easy integral g(x)*s(x) = 10*x^3-15*x^2+4*x-6 indefinite integral = 10/3*x^4 -15/3*x^3 + 4/2*x^2 - 6*x + C oops

Re: [R] Help about nlminb function

2010-12-15 Thread Ben Bolker
many years of experience. Test your objective function with your starting value (it should give a finite value), with values near your starting value (it should give similar answers), and with parameter values that you suspect to be worse (but not crazily worse) (it should give higher values). Ben

Re: [R] How to apitalize leading letters amp; else of personal names?

2010-12-15 Thread Ben Bolker
RockO rock.ouimet at gmail.com writes: Dear R world, Do you know about a function that would capitalize in the correct manner first and family names? I found in the cwhmisc only the CapLeading function, but it just does not do the job, taking care only to capitalize the first letter of

Re: [R] lines and points without margin

2010-12-14 Thread Ben Bolker
coordinates. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] Question about cut()

2010-12-14 Thread Ben Bolker
Tianchan Niu niu at isis.georgetown.edu writes: Dear all, I would like to use cut() to make numerics to factors, the sample codes are as follows. However, the result is not what I want, since r[3] = 9 should be in the interval of 8-10% rather than 2-4%. Maybe cut() is not the right function

Re: [R] Date variable error

2010-12-14 Thread Ben Bolker
Kurt_Helf at nps.gov writes: Greetings In attempting to create a date variable based on month (e.g., February, April, etc.) and year (e.g., 2006) data, wherein I converted Month to a factor with Jan=1...Dec=12, I used the following command:

Re: [R] How to ignore data

2010-12-13 Thread Ben Bolker
Steve Sidney sbsidney at mweb.co.za writes: Dear list I have quite a small data set in which I need to have the following values ignored - not used when performing an analysis but they need to be included later in the report that I write. Can anyone help with a suggestion as to how

Re: [R] How to ignore data

2010-12-13 Thread Ben Bolker
combination of (1) (requested) help to perform the task asked and (2) (unrequested) advice. Personality, philosophy, and the degree of perceived unwisdom/danger in the specified activity determine the mix. cheers Ben Bolker __ R-help@r-project.org

Re: [R] Testing an interaction with a random effect in lmer

2010-12-13 Thread Ben Bolker
, you could try binom~season + (season|group/individual) was the switch from 'individual' above to 'badger' below a slip? Thanks for the clear description. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r

Re: [R] ggplot2 errorbarh

2010-12-12 Thread Ben Bolker
Brian Tsai btsai00 at gmail.com writes: Hi, I'm having problems using the 'width' aesthetic attribute for the geom_errorbarh. This is the same problem reported earlier here, but I'll try to write the problem more clearly: http://www.mail-archive.com/r-help at

Re: [R] Predator Prey Models

2010-12-11 Thread Ben Bolker
Craig O'Connell craigpoconnell at gmail.com writes: I am currently modifying a previously developed predator prey model and was curious if there was a way to add in a disturbance to the model (let's say at time t=100). The disturbance can be the introduction of 40 prey (N=40) and 10

Re: [R] Stricter read.table?

2010-12-10 Thread Ben Bolker
Stavros Macrakis macrakis at alum.mit.edu writes: read.table gives idiosyncratic results when the input is formatted strangely, for example: read.table(textConnection( a'b\nc'd\n),header=FALSE, fill=TRUE,sep=,quote=') = c'd a'b c'd read.table(textConnection( a'b\nc'd\nf'\n'\n),

Re: [R] [r] overlap different line in a xyplot (lattice)

2010-12-10 Thread Ben Bolker
and don't understand ... A reproducible example would be nice too. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide

Re: [R] Complete newbie - create microarray image from data file?

2010-12-09 Thread Ben Bolker
wocket deborahmalley at yahoo.co.uk writes: Hey So sorry to be a total newbie, but i'm just finding my feet with R. I heard on the grapevine i could recreate a scanned microarray image, or at least get a good graphic of it from a just a data file. I have .txt files for illumina

Re: [R] String to array

2010-12-09 Thread Ben Bolker
Romildo Martins romildo.martins at gmail.com writes: how convert x in xarray (numbers)? x [1] 0 - 13 y [1] 11 - 23 z [1] 220 - 9 xarray [1] 0 13 yarray [1] 11 23 zarray [1] 220 9 Is as.numeric(unlist(strsplit(0 - 13,-))) what you want?

Re: [R] Statistics of count data for differential expression

2010-12-09 Thread Ben Bolker
, but I think you might get a more informed answer on the Bioconductor list ... Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html

Re: [R] Plotting 3d surfaces

2010-12-09 Thread Ben Bolker
Barry Rowlingson b.rowlingson at lancaster.ac.uk writes: On Thu, Dec 9, 2010 at 4:20 PM, Uwe Wolfram uwwo at in-chemnitz.de wrote: I am currently working on a project which involves nls-fits of three dimensional surfaces such as ellipsoids or even more complex. I have been searching R

Re: [R] set Gamma parameters in glm model

2010-12-08 Thread Ben Bolker
Rosario Garcia Gil M.Rosario.Garcia at slu.se writes: Hello I hope my question makes sense. It is possible to specify the shape paramenters in a glm model with family Gamma? It doesn't look that way, but you can do a Gamma model with a specified shape parameter (albeit much less

Re: [R] getting R to download data

2010-12-07 Thread Ben Bolker
sachinthaka.abeywardana at allianz.com.au writes: Is it possible to write a program such that it downloads a csv from a given web address? Would be great if this could be done at a particular time during the day as well. Say 9AM monday-friday. downloading a csv file is easy: x -

Re: [R] use pcls to solve least square fitting with constraints

2010-12-06 Thread Ben Bolker
Baoqiang Cao bqcaomail at gmail.com writes: I have a least square fitting problem with linear inequality constraints. pcls seems capable of solving it so I tried it, unfortunately, it is stuck with the following error: M - list() M$y = Dmat[,1] M$X = Cmat M$Ain = as.matrix(Amat)

Re: [R] Using nlminb for maximum likelihood estimation

2010-12-06 Thread Ben Bolker
Joonas - as_trix85 ast_rix85 at hotmail.com writes: I'm trying to estimate the parameters for GARCH(1,1) process. Here's my code: loglikelihood -function(theta) { h=((r[1]-theta[1])^2) p=0 for (t in 2:length(r)) { h=c(h,theta[2]+theta[3]*((r[t-1]-theta[1])^2)+theta[4]*h[t-1]) }

Re: [R] knowing the code-number of factors in a vector

2010-12-03 Thread Ben Bolker
Eduardo Klein eklein at usb.ve writes: I would like to know how R assigns the numeric code to a set of factors in a vector. [snip] It is indeed alphabetical by default. To get it in order of appearance you could do something like set.seed(1001) x -

Re: [R] [R-lme] Extract estimated variances from output of lme?

2010-12-01 Thread Ben Bolker
Tingting Zhan tingting.zhan at jefferson.edu writes: Hi all, I have the output of summary() of an lme object called lme.exp1, for example # summary(lme.exp1) [snip] for the common variance parameter sigma. But if I need the

Re: [R] Zooming in to a ggplot (a sort of ylim, but ylim won't do)

2010-11-30 Thread Ben Bolker
/group/ggplot2 that is probably better than R-help for ggplot-specific questions. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html

Re: [R] accuracy of GLM dispersion parameters

2010-11-30 Thread Ben Bolker
Timothy_Handley at nps.gov writes: I'm confused as to the trustworthiness of the dispersion parameters reported by glm. Any help or advice would be greatly appreciated. [snip] Specifics: The summary function says that my fitted GLM has a dispersion parameter=15.8. On the other hand, the

Re: [R] Adding noise

2010-11-30 Thread Ben Bolker
Jim Silverton jim.silverton at gmail.com writes: Hello, I have some discrete pvalues and I would like to sort them. Then add random noise so that they are ordered the same way as the original pvalues. Off course I don't want any pvalues less than 0 or greater than 1. Any ideas on how to do

Re: [R] Filter a Matrix

2010-11-30 Thread Ben Bolker
Jorge Ivan Velez jorgeivanvelez at gmail.com writes: Hi Romildo, One possible way would be the following: index - apply(m, 1, function(row) any(a %in% row)) m[index, ] HTH, Jorge Does the original poster mean index - apply(m, 1, function(row) all(a %in% row)) m[index, ] ?

Re: [R] Problems in running affylmGUI

2010-11-29 Thread Ben Bolker
Lorenzo Melchor Lorenzo.Melchor at icr.ac.uk writes: I am trying to run affylmGUI on my mac computer. I have already installed the Tlc package as well as Bwidgets through ActiveTcl conversion installing files. However, when running affylmGUI() on R, I keep getting the message in the

Re: [R] Need help

2010-11-24 Thread Ben Bolker
. Ben Bolker __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] compare GLM coefficients

2010-11-23 Thread Ben Bolker
Michael Bedward michael.bedward at gmail.com writes: Hello Kayce, My (very basic) understanding is that you can't directly compare the coefficients across models that have different response variables, nor could you use AIC and similar metrics of model goodness of fit. Instead, I think

Re: [R] quot;helpquot;

2010-11-23 Thread Ben Bolker
Francial Giscard LIBENGUE libengue at gmail.com writes: S'il vous plait, j'ai un problème avec la fonction gamma je n'arrive pas à bienécrire l'exposant j'ai utilisé ^ et ça ne marche pas. cordialemont ici on parle anglais (je ne sais pas s'il y a une autre liste ou on pourrait poser

Re: [R] Is it possible to make a matrix to start at row 0?

2010-11-22 Thread Ben Bolker
Bert Gunter gunter.berton at gene.com writes: Eh??? Why would you want to do that?? (R isn't C). So the simple answer is: you can't. The other answer is, well of course you sort of can via, e.g. for(i in 0:9) { z - myMatrix[i+1,] ... } But as Josh said, I think this falls

Re: [R] Fast Two-Dimensional Optimization

2010-11-22 Thread Ben Bolker
be able to choose better starting conditions. You may be able to pick an optimization method that is more suitable for your objective function (see ?optim and the optimx package on r-forge). Ben Bolker __ R-help@r-project.org mailing list https

Re: [R] Question on overdispersion

2010-11-19 Thread Ben Bolker
cct663 cct663 at gmail.com writes: I have a few questions relating to overdispersion in a sex ratio data set that I am working with (note that I already have an analysis with GLMMs for fixed effects, this is just to estimate dispersion). The response variable is binomial because nestlings can

Re: [R] generalized linear regression - function glm - dismissed predictors - more information about simulated data

2010-11-18 Thread Ben Bolker
Bert Gunter gunter.berton at gene.com writes: [snip snip snip] Cheers, Bert P.S. Your results look fishy, even for a simulation. The extremely low standard errors and rank deficiencies strongly suggest to me that your methodology is faulty and that you are getting a bunch of baloney. I

Re: [R] dmultinomial

2010-11-18 Thread Ben Bolker
Alexander Shenkin ashenkin at ufl.edu writes: Hello All, I'm trying to run a maximum likelihood analysis using dmultinomial (i'm avoiding dmultinom as I'd like to run it with vectors for the ML stuff). However, I'm having a hard time getting even the simplest example running. Any help

Re: [R] Sample covariance matrix in R

2010-11-18 Thread Ben Bolker
Alaios alaios at yahoo.com writes: Hello everyone. I would like to find the sample covariance matrix using R. So far I read on the wikipedia what a sample_covariance is http://en.wikipedia.org/wiki/Sample_covariance according to wikipedia one vector is enough to calculate the sample

Re: [R] Bug in agrep computing edit distance?

2010-11-17 Thread Ben Bolker
Dickison, Daniel ddickison at carnegielearning.com writes: The documentation for agrep says it uses the Levenshtein edit distance, but it seems to get this wrong in certain cases when there is a combination of deletions and substitutions. For example: agrep(abcd, abcxyz, max.distance=1)

Re: [R] rgl, multiple graphics ??

2010-11-17 Thread Ben Bolker
skan juanpide at gmail.com writes: How can I get multipanel conditioning graphics with rgl as I do with lattice | For example I have three variables x, y, z, w. Where x,y,z are continuous and w is categorical or discrete. I want to use plot3d(x,y,z) for each value of w in a panel

<    4   5   6   7   8   9   10   11   12   13   >