Re: [R] boxplot

2010-09-29 Thread Dennis Murphy
http://www.netmba.com/statistics/plot/box/ ...found via Google search. HTH, Dennis On Tue, Sep 28, 2010 at 10:06 PM, Luis Felipe Parra < felipe.pa...@quantil.com.co> wrote: > Hello, does somebody know in a boxplot, what does each element in the > boxplot represent? > > 1. lines at the extremes

Re: [R] A problem with plotting a long expression in ylab ?

2010-09-29 Thread Tal Galili
My honor. A short question: if there is something in the device that is sensitive to the overlapping of the text, then is it possible to add a warning massage output when the length of the text is longer then the device dimensions? With much respect, Tal Contact Details:-

Re: [R] get response from a glm

2010-09-29 Thread Michael Bedward
Hello, The predict.glm is your friend. Type ?predict.glm to see the help page. Michael On 29 September 2010 12:45, xinxin xx wrote: > > Hi everyone: > >  I am new to R and I have a really basic question. >     I have already got a generalized linear model from some dataset, say y=b0 > + b1X1

Re: [R] String split and concatenation

2010-09-29 Thread Steven Kang
x <- rep(letters[1:3], 2) Are there any ways to transform & assign the above as the one shown below to an object? (in exact format; i.e length of 1 & class of character), i.e >x "('a', 'b', 'c', 'a', 'b', 'c')" Highly appreciate for any advice. On Wed, Sep 29, 2010 at 3:33 PM, wrote: > dump(

Re: [R] name ONLY one column // empty.dimnames() in 'sfsmisc'

2010-09-29 Thread Martin Maechler
> "IC" == Ivan Calandra > on Mon, 27 Sep 2010 16:59:31 +0200 writes: IC> Hi, IC> I'm not sure it's even possible (and if it is I don't know how, but I'm IC> no expert). yes it is possible (in some way), see below. IC> But I think it doesn't make much sense to have o

[R] Validation / Training - test data

2010-09-29 Thread Sam
Dear List, I have developed two models i want to use to predict a response, one with a binary response and one with a ordinal response. My original plan was to divide the data into test (300 entries) and training (1000 entries) and check the power of the model by looking at the % correct predi

[R] drop.terms and [.terms ignores intercept

2010-09-29 Thread Niels Richard Hansen
Dear R-help list The functions drop.terms and [.terms ignores if the intercept has been explicitly removed. Is that a deliberate feature? For instance, drop.terms(terms(~a+b-1),1) terms(~a+b-1)[2] R version 2.12.0 Under development (unstable) (2010-09-13 r52905) Best, Niels -- Niels Richard

Re: [R] drop.terms and [.terms ignores intercept

2010-09-29 Thread peter dalgaard
On Sep 29, 2010, at 10:29 , Niels Richard Hansen wrote: > The functions drop.terms and [.terms ignores if the intercept > has been explicitly removed. Is that a deliberate feature? Perhaps rather an unimplemented one. The root cause is that both functions use reformulate() on the "term.labels"

Re: [R] constrained optimization -which package?

2010-09-29 Thread Hans W. Borchers
Leonardo Monasterio gmail.com> writes: > > Dear R users, > > In the function bellow I want to find the maximum value of v, > subject to the constrain that the sum of x is equal to 1. > I want to maximize: > v<-t(x)%*%distance%*%x > > Subject to: > sum(x)=1 I do not see why you would take t

Re: [R] Use R in Visual Basic Environment

2010-09-29 Thread Christophe Bouffioux
Hi Soumen, it depends what you mean by "embedded" what i have done once is to run a R script in batch mode from an access application, the R code import an access table, with the RODBC package, produce some table and graph which are compiled on the fly in html output, using HWRITER or R2HTML packa

Re: [R] drop.terms and [.terms ignores intercept

2010-09-29 Thread Niels Richard Hansen
On 29/09/10 11.13, peter dalgaard wrote: On Sep 29, 2010, at 10:29 , Niels Richard Hansen wrote: The functions drop.terms and [.terms ignores if the intercept has been explicitly removed. Is that a deliberate feature? Perhaps rather an unimplemented one. The root cause is that both function

[R] how to rotate the x axis lable to an interested angle?

2010-09-29 Thread komais
http://r.789695.n4.nabble.com/file/n2718591/QQ%E6%88%AA%E5%9B%BE%E6%9C%AA%E5%91%BD%E5%90%8D--1.png I am a beginner for R,and i could not solve this problem.who can help me to solve it ? how to rotate the x axis lable to an interested angle as the picture show? -- View this message in cont

[R] 3D Graphics

2010-09-29 Thread JoH
Dear All, I have made a scatter plot and placed a plane within it using scatterplot3d. However, I have been asked for the data points to be a surface plot or have the plane more closely resemble the data rather than show trends. I have since tried to use the rgl package. Why doesn't this package

Re: [R] Splitting data in to multiple boxplots

2010-09-29 Thread deadlyspider
Ok, I don't think I was specific enough. The data originally came in this form 1 a 12 2 b 4 3 a 3 4 c 54 5 a 12 6 b 11 7 c 9 8 c 2 . . . . . . . . . Where I sorted by the second column (NB the second column is the categories and they have long names). I would then like

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Sam
I am looking to do the same but am a bit confused > and apply the inverse link function for your model. i understand up to this point and i understand what this means, however i am unsure why it needs to be done and how you do it - i.e i use family="binomial" is this wrong if i use this method

Re: [R] Regular expressions: offsets of groups

2010-09-29 Thread Titus von der Malsburg
Bill, Michael, good to see I'm not the only one who sees potential for improvements in the regexpr domain. Adding a subpattern argument is certainly a step in the right direction and would make my life much easier. However, in my application I need to know not only the position of one group but a

[R] svg plot and dashed lines

2010-09-29 Thread Ivan Calandra
Dear users, When I boxplot(), the lines of the whiskers are dashed. However, when I save in an svg file, the dashed lines of the whiskers are not dashed anymore. How can I have the dashed lines in the svg file? I don't have this problem with a ps file, but I cannot edit such file as easily as

Re: [R] Splitting data in to multiple boxplots

2010-09-29 Thread Martyn Byng
Hi, Something like bb = data.frame(label=c("a","b","a","b","c","a","b","c"),val=c(4,2,1,6,4,3,2, 1)) l = split(bb,bb$label) par(mfrow=c(2,2)) lapply(l,function(a) {boxplot(a$val)}) might be what you are looking for Martyn -Original Message- From: r-help-boun...@r-project.org [mailto:r-

[R] Problems extracting p-value from summary(aov(...))

2010-09-29 Thread syrvn
Hi, I did a aov and used summary to obtain the p-value. I tried many ways to extract the p-value from the summary result but failed. Among others I tried the following: > test.summary <- > summary(aov(data[,1]~time.points+Error(subject/time.points))) > test.summary Error: subject Df

[R] matrix plot

2010-09-29 Thread hairryharry
Hi, Fairly new to R - have done basic plots but now faced with plotting a matrix/table of results -I know what I want but cannot find out how to do it. Basically have individual questions ( x) to which an organization can rate themselves 1-10 (y) what I want to show is a matrix/density type

[R] Adding two data.frames.

2010-09-29 Thread Joel
Hi I have two data frames that contains the same sort of data and I want do add them together to get one big data frame, anyone know how to do that? ex: data.frame1 A B C 1 2 3 4 5 6 7 8 9 and data.frame2 A B C 9 8 7 6 5 4 3 2 1 Would then become one big set: data.frame3 A B C 1 2 3 4 5 6 7

Re: [R] Adding two data.frames.

2010-09-29 Thread Ivan Calandra
Hi, Take a look at rbind() HTH, Ivan Le 9/29/2010 13:24, Joel a écrit : > Hi > > I have two data frames that contains the same sort of data and I want do add > them together to get one big data frame, anyone know how to do that? > > ex: > data.frame1 > A B C > 1 2 3 > 4 5 6 > 7 8 9 > > and > d

Re: [R] Regular expressions: offsets of groups

2010-09-29 Thread Michael Bedward
I'd definitely be a customer for it Titus. And it does seem like an obvious hole in regex processing in R that cries out to be filled. Um, ggregexpr isn't the sexiest of function names :) Perhaps we can think of something a little easier ? How is your C coding ? Bill ? Anyone else ? I could hav

Re: [R] Regular expressions: offsets of groups

2010-09-29 Thread Titus von der Malsburg
On Wed, Sep 29, 2010 at 1:58 PM, Michael Bedward wrote: > How is your C coding ? Bill ? Anyone else ?  I could have a got at > writing some prototype code to test in the next few days, though if > someone else with decent C skills is itching to do it please speak up. We have a skilled C- and R-pr

Re: [R] 3D Graphics

2010-09-29 Thread Duncan Murdoch
On 29/09/2010 6:00 AM, JoH wrote: Dear All, I have made a scatter plot and placed a plane within it using scatterplot3d. However, I have been asked for the data points to be a surface plot or have the plane more closely resemble the data rather than show trends. I have since tried to use the r

Re: [R] Problems extracting p-value from summary(aov(...))

2010-09-29 Thread Dennis Murphy
Hi: Try this: test.summary[[1]][, 5] It should return a vector of p-values, the last being NA. In your case, since there is only one non-NA p-value, it is enough to do test.summary[[1]][, 5][1] You mean that wasn't obvious? :) Explanation: summary(aovobj) actually returns a list, but that's

Re: [R] how to rotate the x axis lable to an interested angle?

2010-09-29 Thread Jim Lemon
On 09/29/2010 07:19 PM, komais wrote: http://r.789695.n4.nabble.com/file/n2718591/QQ%E6%88%AA%E5%9B%BE%E6%9C%AA%E5%91%BD%E5%90%8D--1.png I am a beginner for R,and i could not solve this problem.who can help me to solve it ? how to rotate the x axis lable to an interested angle as the picture

Re: [R] Adding two data.frames.

2010-09-29 Thread Joel
Thx for the help works very well for me. -- View this message in context: http://r.789695.n4.nabble.com/Adding-two-data-frames-tp2718771p2718901.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing list https:/

Re: [R] matrix plot

2010-09-29 Thread Dennis Murphy
Hi: Are you thinking of a levelplot/heatmap? Some places to look: ?levelplot in the lattice package ?geom_tile in the ggplot2 package ?heatmap2 in the gplots package You can find many more heatmap functions in R; try library(sos)# install first if you don't have it - *very* handy fo

Re: [R] Validation / Training - test data

2010-09-29 Thread Frank Harrell
Split sample validation is highly unstable with your sample size. The rms package can help with bootstrapping or cross-validation, assuming you have all modeling steps repreated for each resample. Frank - Frank Harrell Department of Biostatistics, Vanderbilt University -- View this message

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Ben Bolker
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 ## from ?glm counts <- c(18,17,15,20,10,20,25,13,12) outcome <- gl(3,1,9) treatment <- gl(3,3) d.AD <- data.frame(treatment, outcome, counts) glm.D93 <- glm(counts ~ outcome + treatment, family=poisson, data=d.AD) ## predict on 'link'

Re: [R] plotting multiple animal tracks against Date/Time

2010-09-29 Thread Gabor Grothendieck
On Wed, Sep 29, 2010 at 7:52 AM, Struve, Juliane wrote: > I will post the example again to see if its readable now. My question is why > does read.zoo(file=filenames,) work and  lapply(filenames, read.zoo,...) > does not ? Since I am reading the same file in both statements I just do not > k

Re: [R] matrix plot

2010-09-29 Thread Thomas Stewart
HH- I'm not familiar with the plots you mention, but the following is a quick attempt to create the plot you describe. data<-data.frame( org=1:10, q1=sample(1:10,replace=T), q2=sample(1:10,replace=T), q3=sample(1:10,replace=T)) # This generates a random data set like the one you describ

Re: [R] Problems extracting p-value from summary(aov(...))

2010-09-29 Thread peter dalgaard
On Sep 29, 2010, at 14:25 , Dennis Murphy wrote: > > test.summary[[1]][, 5][1] > > You mean that wasn't obvious? :) Worse, it doesn't actually work... > test.summary <- summary(npk.aovE) > test.summary[[1]][, 5] Error in `[.default`(test.summary[[1]], , 5) : incorrect number of dimension

Re: [R] Validation / Training - test data

2010-09-29 Thread Sam
Thanks for this, I had used > validate(model0, method="boot",B=200) To get a index.corrected Brier score, However i am also wanting to bootstrap the predicted probabilities output from predict(model1, type = "response") to get a idea of confidence, or am i best just using se.fit = TRUE an

[R] short captions for xtable?

2010-09-29 Thread cuz
Hi, For my dissertation, I've made copious use of xtable. I've just gotten stumped however. I'm a fan of extended captions explaining the table, but now I have to assemble a a list of tables and the captions are unwieldy. I presume xtable calls LaTeX's \caption function. Is there a way to include

Re: [R] Splitting data in to multiple boxplots

2010-09-29 Thread Joshua Wiley
Hi, The form of the data is not terribly important neither is whether it was sorted as boxplots are not order dependent are category "a" is "a" sorted or not. See below for individual plots with your new data. # read in data dat <- read.table(textConnection(" 1 a 12 2 b 4 3 a 3 4 c 54 5

Re: [R] 3D Graphics

2010-09-29 Thread Ben Bolker
Duncan Murdoch gmail.com> writes: > > On 29/09/2010 6:00 AM, JoH wrote: > > Are there anyother ways in which I can create a surface plot? persp() (in base R) is less flexible than rgl::persp3d, doesn't do hidden line removal, etc., but does appear in the regular R graphics window and can be

[R] Fitting a half-ellipse curve

2010-09-29 Thread Niklaus Hurlimann
Dear mailing list, I have following array: X2 Y2 [1,] 422.7900 6.0 [2,] 469.8007 10.5 [3,] 483.9428 11.0 [4,] 532.4917 25.5 [5,] 596.1942 33.5 [6,] 630.8496 40.5 [7,] 733.2996 45.0 [8,] 946.4779 32.0 [9,] 996.8068 35.5 [10,] 1074

Re: [R] how to rotate the x axis lable to an interested angle?

2010-09-29 Thread Ben Bolker
komais yahoo.com.cn> writes: > how to rotate the x axis lable to an interested angle as the picture show? __ R-help@r-project.org mailing list https://stat.ethz

Re: [R] how to rotate the x axis lable to an interested angle?

2010-09-29 Thread komais
Thank you very much. -- View this message in context: http://r.789695.n4.nabble.com/how-to-rotate-the-x-axis-lable-to-an-interested-angle-tp2718591p2718963.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing

Re: [R] Problems extracting p-value from summary(aov(...))

2010-09-29 Thread Dennis Murphy
Hi: On Wed, Sep 29, 2010 at 5:56 AM, peter dalgaard wrote: > > On Sep 29, 2010, at 14:25 , Dennis Murphy wrote: > > > > > test.summary[[1]][, 5][1] > > > > You mean that wasn't obvious? :) > > Worse, it doesn't actually work... > > > test.summary <- summary(npk.aovE) > > test.summary[[1]][, 5]

Re: [R] plotting multiple animal tracks against Date/Time

2010-09-29 Thread Struve, Juliane
I will post the example again to see if its readable now. My question is why does read.zoo(file=filenames,) work and lapply(filenames, read.zoo,...) does not ? Since I am reading the same file in both statements I just do not know how to interpret "Error in strptime(x, format, tz = tz) : in

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Sam
Hi Ben and list, Sorry to be a pain! I have followed your code, and modified it - > pp <- predict(model1,se.fit=TRUE, type = "response") >> etaframe <- > + with(pp,cbind(fit,lower=fit-1.96*se.fit,upper=fit+1.96*se.fit)) >> pframe <- plogis(etaframe) >> pframe My response variable is 0 or 1, the

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Sam
Hi Ben and list, Sorry to be a pain! I have followed your code, and modified it - > pp <- predict(model1,se.fit=TRUE, type = "response") >> etaframe <- > + with(pp,cbind(fit,lower=fit-1.96*se.fit,upper=fit+1.96*se.fit)) >> pframe <- plogis(etaframe) >> pframe My response variable is 0 or 1, the

[R] FW: creating a custom background

2010-09-29 Thread Arenson, Ethan
Hi. I want to create a plot with Pantone654 as the background. The RGB for this color is (0,61,121), which corresponds to a hex of #003D79. How do I specify the bg parameter for this? All Best, Ethan [[alternative HTML version deleted]] __

Re: [R] FW: creating a custom background

2010-09-29 Thread Henrique Dallazuanna
Try this: par(bg = '#003D79') On Wed, Sep 29, 2010 at 11:14 AM, Arenson, Ethan wrote: > > Hi. > > I want to create a plot with Pantone654 as the background. The RGB for this > color is (0,61,121), which corresponds to a hex of #003D79. How do I specify > the bg parameter for this? > > All Best,

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Ben Bolker
On 10-09-29 10:04 AM, Sam wrote: > Hi Ben and list, > > Sorry to be a pain! I have followed your code, and modified it - > **You should not use type="response" here.** The point is that the (symmetric) confidence intervals are computed on the link/linear predictor scale, and then inverse-link-

[R] generalized additive mixed models for ordinal data

2010-09-29 Thread Camarda, Carlo Giovanni
Dear R-users, Is there any R-function for fitting generalized additive mixed models for ordinal data? Do they actually make some sense? I can fit a generalized linear mixed model for ordinal data using the function clmm(ordinal) and I'm able to cope with generalized additive model for ordi

Re: [R] short captions for xtable?

2010-09-29 Thread Marc Schwartz
On Sep 29, 2010, at 8:31 AM, cuz wrote: > > Hi, > > For my dissertation, I've made copious use of xtable. I've just gotten > stumped however. I'm a fan of extended captions explaining the table, but > now I have to assemble a a list of tables and the captions are unwieldy. I > presume xtable cal

[R] nlminb and optim

2010-09-29 Thread Doran, Harold
I am using both nlminb and optim to get MLEs from a likelihood function I have developed. AFAIK, the model I has not been previously used in this way and so I am struggling a bit to unit test my code since I don't have another data set to compare this kind of estimation to. The likelihood I hav

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Chris Mcowen
Right, that makes sense, thanks The reason i used type= response was i wanted to convert the predicted probabilities to the response scale, as surely this is the scale at which a 95CI value is most useful for? I.e >> pp <- predict(model1,se.fit=TRUE, type = "response") 1 0.68 Probability

[R] getDLLVersion

2010-09-29 Thread Kyle Covington
Hi, I'm just learning to write R extensions in C and to embed R in C. I was trying to get through the example in the help page on calling the .dll directly ( http://cran.r-project.org/doc/manuals/R-exts.html#Calling-R_002edll-directly ). When I compile I consistently get the error that getDLLVer

Re: [R] FW: creating a custom background

2010-09-29 Thread Thomas Stewart
Ethan- You need to be more explicit about what you mean by 'background'. Do you mean: (a) the entire plot including margins?, or (b) only the plotting area?, or (c) a different color for both margins and plotting area? If you want (a), the solution is par(bg = '#003D79'). If you want (b), the s

[R] What's the meaning of "Species ~ ." in IRIS data

2010-09-29 Thread Gundala Viswanath
I am refering to a function call like this: >data(iris) >x <- svmlight(Species ~ ., data = iris) I tried to see the content of it by typing: > Species ~ . but it gives nothing. How can I see it's content ? - P.Dubois __ R-help@r-project.org mailing

Re: [R] What's the meaning of "Species ~ ." in IRIS data

2010-09-29 Thread Duncan Murdoch
On 29/09/2010 10:51 AM, Gundala Viswanath wrote: I am refering to a function call like this: >data(iris) >x<- svmlight(Species ~ ., data = iris) I tried to see the content of it by typing: > Species ~ . but it gives nothing. How can I see it's content ? str(Species ~ .) will tell you tha

Re: [R] What's the meaning of "Species ~ ." in IRIS data

2010-09-29 Thread Prof Brian Ripley
On Wed, 29 Sep 2010, Duncan Murdoch wrote: On 29/09/2010 10:51 AM, Gundala Viswanath wrote: I am refering to a function call like this: >data(iris) >x<- svmlight(Species ~ ., data = iris) I tried to see the content of it by typing: > Species ~ . but it gives nothing. How can I see it's co

[R] R crashes when loading rgl package before minqa package

2010-09-29 Thread Gaspard Lequeux
Hej, Calling newuoa (from the minqa package) makes R crash when the package rgl is loaded first. This however only on certain selected data. The data used for testing (saved to 'bugs.R'): xvals = c(1,2,4,5,7,8,9,10,11,12,14,15,16,18,19,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36) yval

Re: [R] generalized additive mixed models for ordinal data

2010-09-29 Thread Dennis Murphy
Hi: You could look into the gamm4 package. Its description is: Fit generalized additive mixed models via a version of mgcv's gamm function, using lme4 for estimation via Fabian Scheipl's trick. HTH, Dennis On Wed, Sep 29, 2010 at 7:28 AM, Camarda, Carlo Giovanni < cama...@demogr.mpg.de> wrote:

[R] (OT) Change of email address

2010-09-29 Thread Ted Harding
Apologies for bothering anyone who may not be interested in this, but some of you will, for instance, have my current email address in your address books, etc. As result of a new policy by Manchester University, retired former staff who no longer contribute actively to research in their former de

Re: [R] short captions for xtable?

2010-09-29 Thread cuz
Thanks. I didn't see any obvious way to do it either. It looks like the caption option has room for additional input that are as yet not designated. I'll take a look at the latex() possibility. Best, cuz -- View this message in context: http://r.789695.n4.nabble.com/short-captions-for-xtable-tp2

[R] R Spracheinstellung

2010-09-29 Thread Keller Tobias (kelleto0)
sehr geehrte Damen und Herren Für unseren Statistik Unterricht brauchen wir das R-Programm. Ich habe das Programm heruntergeladen, deutsch gewählt und installiert. Das Problem ist nach 3mal neu installieren, dass das Programm immer auf englisch kommt. Können Sie mir helfen? Vg Tobias Keller

[R] R Graphic - Tellis as a potential

2010-09-29 Thread Jeevan Duggempudi
Hello all, I have been meaning to learn R for a while and have just subscribed to this list. I am planning to give R a shot at one of my live projects. I am looking to explore graphical features of R on my data below. Sample Data: Cat1 - Cat2 - Cat3 - Cat4 - NumPeople - Salary H - L - H -

Re: [R] Problems extracting p-value from summary(aov(...))

2010-09-29 Thread Dennis Murphy
Hi: Someone off-list (Josh Wiley - thank you) mentioned the Error() term in the OP's ANOVA, which I missed in responding to the post - sorry for the misinformation. Using the npk example with code that Josh showed me, we have, for the following model, npk.aov2 <- aov(yield ~ N*P*K + Error(block/P

[R] [R-pkgs] caret package version 4.63

2010-09-29 Thread KuhnA03
Version 4.63 of the caret package is now on CRAN. caret can be used to tune the parameters of predictive models using resampling, estimate variable importance and visualize the results. There are also various modeling and "helper" functions that can be useful for training models. caret has wrappe

Re: [R] plotting multiple animal tracks against Date/Time

2010-09-29 Thread Dennis Murphy
Hi: This 'works' on the lapply end: # Function to read one file from the list: g <- function(x) read.zoo(file = x, header = TRUE, FUN = as.chron, sep = ",", colClasses = c("NULL", "NULL", "character", "numeric")) # Apply to all files in list: lapply(filenames, g) [[1]] (0

Re: [R] (OT) Change of email address

2010-09-29 Thread Vojtěch Zeisek
Hello, go to https://stat.ethz.ch/mailman/options/r-help/y...@email and if You do not remember Your password, use Password reminder (down) to mail it to Your address. Then login and do all needed changes. You can replace r-hep in link above with r-sig-phylo, r-announce and so on. And of course r

Re: [R] R Spracheinstellung

2010-09-29 Thread Berwin A Turlach
G'day Tobias, On Wed, 29 Sep 2010 14:01:10 + "Keller Tobias (kelleto0)" wrote: > Für unseren Statistik Unterricht brauchen wir das R-Programm. > Ich habe das Programm heruntergeladen, deutsch gewählt und > installiert. Das Problem ist nach 3mal neu installieren, dass das > Programm immer auf

[R] 95% confidence intercal with glm

2010-09-29 Thread Sam
Dear List and Ben ( I apologise if this has been sent twice, but it is not showing in my sent folder and i have been having trouble with my email of late) Right, that makes sense, thanks The reason i used type= response was i wanted to convert the predicted probabilities to the response scale,

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Ben Bolker
[I'm a little confused: are you "Sam Smith" or "Chris Mcowen" ... ?] This is admittedly a bit confusing, but the best scale on which to compute standard errors is the link scale. It turns out (I hadn't realized this) that predict.glm does give you not-crazy answers when you ask for se.fit=T

Re: [R] 95% confidence intercal with glm

2010-09-29 Thread Sam
Thats great thanks very much for your help On 29 Sep 2010, at 17:30, Ben Bolker wrote: [I'm a little confused: are you "Sam Smith" or "Chris Mcowen" ... ?] This is admittedly a bit confusing, but the best scale on which to compute standard errors is the link scale. It turns out (I hadn't r

[R] Simplify, several Ave or aggregates

2010-09-29 Thread skan
Hello. How can I write this all in one line? mydata is a zoo series, limit is a numeric vector of the same size tmp <- ave(coredata(mydata),as.Date(index(mydata)),FUN = function(x) ( (cummax(x)-x )) ) tmp <- (tmp < limit) final <- ave(coredata(tmp),as.Date(index(mydata)),FUN = function(x) cumpr

Re: [R] R Spracheinstellung

2010-09-29 Thread peter dalgaard
On Sep 29, 2010, at 18:21 , Berwin A Turlach wrote: > G'day Tobias, > > On Wed, 29 Sep 2010 14:01:10 + > "Keller Tobias (kelleto0)" wrote: > >> Für unseren Statistik Unterricht brauchen wir das R-Programm. >> Ich habe das Programm heruntergeladen, deutsch gewählt und >> installiert. Das Pr

Re: [R] Validation / Training - test data

2010-09-29 Thread Frank Harrell
It all depends on the ultimate use of the results. Frank - Frank Harrell Department of Biostatistics, Vanderbilt University -- View this message in context: http://r.789695.n4.nabble.com/Validation-Training-test-data-tp2718523p2719370.html Sent from the R help mailing list archive at Nabbl

[R] Ranked Set Sampling

2010-09-29 Thread Ahmed Albatineh
Dear All; I have searched to see if any code in R was written to calculate mean and variance of a Ranked Set Sample, but did not find any. Is there any package for RSS, or kindly can somebody share a code he/she wrote, I am very grateful and willing to acknowledge that in my work. Thanks much Ahm

Re: [R] move colorkey

2010-09-29 Thread Peter Ehlers
On 2010-09-28 18:39, Marlin Keith Cox wrote: When using a wireframe, I need to move the colorkey from the "right" position (default0 towards the plot. I have also needed to adjust the height and used the code colorkey=list(T,space='right',height=.5) I have looked at documents (within levelplot

Re: [R] (OT) Change of email address

2010-09-29 Thread Kevin E. Thorpe
Ted is well aware of how to change his list email. He was advising people on the list who who have his old email address in their address books to remove it. On 09/29/2010 12:16 PM, Vojtěch Zeisek wrote: Hello, go to https://stat.ethz.ch/mailman/options/r-help/y...@email and if You do not remem

Re: [R] drawing samples based on a matching variable

2010-09-29 Thread Charles C. Berry
On Tue, 28 Sep 2010, L Brown wrote: Hi, everyone. I have what I hope will be a simple coding question. It seems this is a common job, but so far I've had trouble finding the answer in searches. I have two matrices (x and y) with a different number of observations in each. I need to draw a rando

[R] eha aftreg overall p-value

2010-09-29 Thread T. Smithson
Dear useRs, I am currently fitting an advanced failure time model using Göran Broström's excellent "eha" library with the "aftreg" command. My question: How do I interpret the "Overall p-value", that is reported at the very bottom of the output? I already figured out it must be a chi-square test,

Re: [R] subtraction based on two groups in a dataframe

2010-09-29 Thread 1Rnwb
Thanks for the help. Sharad On Mon, Sep 27, 2010 at 9:12 PM, Remko Duursma [via R] < ml-node+2716469-935075351-6...@n4.nabble.com > wrote: > Try something like this: > > > > dfr <- read.table(textConnection("plate.id well.id Group HYB > rlt1 > 1 P1 A1 Control SKOV3hyb 0.

Re: [R] Table with different digit number

2010-09-29 Thread Nicola Sturaro Sommacal (Quantide srl)
Thank you very much for your solution but it works only in a dataframe object. If I am using an ftable object, it doesn't run. I use, as a workaround, to fill with blank spaces the left of each number, so when I print the table, it appears aligned to right. But, obviously, this doesn't work for t

[R] executing loop

2010-09-29 Thread cassie jones
Dear All, I am trying to define a loop for a m*n matrix, where i=1:n and j=1:m. Unlike the usual for loop, i should go in the following way: For j=1, i=1,2,3,n For j=2, i=n,n-1,n-2,..,1 For j=3, i=1,2,3,.n etc. which means i should go in either increasing or decreasing order alternat

[R] Converting a line by line program into an array to perform summary stats

2010-09-29 Thread George Coyle
I am trying to turn several lines of information into a variable. I used the filx function to input my file then the readlines to qualify what I want. Essentially I have data in a file every 10 minutes through a day for several years down a column: date time value 9/28/10 02:00 13 9/28/10 0

Re: [R] executing loop

2010-09-29 Thread Peter Langfelder
for (j in 1:n) { if (j%%2==0) { iRange = c(n:1) } else iRange = c(1:n) for (i in iRange) { your code } } Peter On Wed, Sep 29, 2010 at 10:40 AM, cassie jones wrote: > Dear All, > > > I am trying to define a loop for a m*n matrix, where i=1:n and j=1:m. Un

Re: [R] Use R in Visual Basic Environment

2010-09-29 Thread Liviu Andronic
Hello On Tue, Sep 28, 2010 at 1:39 PM, Soumen Pal wrote: > I need your kind help regarding the following: > > I wish to know is there any way to use R in Visual Basic environment. I want > to develop a VB application where R can be embedded (R will work as a back > end statistical engine). If ava

[R] Exponential integral

2010-09-29 Thread Mishra, Srikanta
Is there an R function for evaluating the exponential integral Ei(x) = INT(-inf,x) exp(t)/t dt [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting gu

[R] resampling issue

2010-09-29 Thread Michael Larkin
I am trying to get R to resample my dataset of two columns of age and length data for fish. I got it to work, but it is not resampling every replicate. Instead, it resamples my data once and then repeated it 5 times. Here is my dataset of 9 fish samples with an age and length for each one: A

Re: [R] Exponential integral

2010-09-29 Thread Ben Bolker
Mishra, Srikanta battelle.org> writes: > > Is there an R function for evaluating the exponential integral > > Ei(x) = INT(-inf,x) exp(t)/t dt Try the gsl package. Also library(sos); findFn("{exponential integral}") although admittedly it doesn't find the Expint page in the gsl package ...

Re: [R] resampling issue

2010-09-29 Thread Henrique Dallazuanna
I think that you want: replicate(5, growth[sample(9,12,replace=T),], simplify = FALSE) On Wed, Sep 29, 2010 at 3:19 PM, Michael Larkin wrote: > I am trying to get R to resample my dataset of two columns of age and > length > data for fish. I got it to work, but it is not resampling every repli

Re: [R] spplot cuts

2010-09-29 Thread bbolker
Hmmm. Maybe a documentation typo in ?spplot. If you follow the documentation through to ?levelplot, you find that cuts: number of levels the range of ‘z’ would be divided into (no mention of actual breakpoints) but: at: numeric vector giving breakpoints along the range of ‘z’.

Re: [R] Converting a line by line program into an array to perform summary stats

2010-09-29 Thread Dieter Menne
George Coyle wrote: > > I am trying to turn several lines of information into a variable. I used > the filx function to input my file then the readlines to qualify what I > want. Essentially I have data in a file every 10 minutes through a day > for > several years down a column: > > date tim

Re: [R] String split and concatenation

2010-09-29 Thread Greg Snow
> paste( '(', paste( "'", rep(letters[1:3],2), "'", sep="", collapse=','), ')', > sep="" ) [1] "('a','b','c','a','b','c')" If you need the space after the comma then just change ',' to ', '. The outer paste can be replaced with sprintf (and that may be more readable). -- Gregory (Greg) L. Sno

[R] New package GAD (General ANOVA Design)

2010-09-29 Thread Maurício Camargo
Hi, everyone. GAD package analyses complex ANOVA models with any combination of orthogonal/nested and fixed/random factors, as described by Underwood (1997). There are two restrictions: (i) data must be balanced; (ii) fixed nested factors are not allowed. Homogeneity of variances is checked using

Re: [R] matrix plot

2010-09-29 Thread hairryharry
Thanks, Thats great just what I was trying to do. HH Thomas Stewart wrote: HH- I'm not familiar with the plots you mention, but the following is a quick attempt to create the plot you describe. data<-data.frame( org=1:10, q1=sample(1:10,replace=T), q2=sample(1:10,replace=T), q3=sa

[R] Trying to avoid loop structure

2010-09-29 Thread Mathieu Beaulieu
Dear R-helpers, I'm trying to associate linear coefficients (intercept and slope) to tens of thousands of observations based on a table with benchmark values. #Example - Value table and their corresponding coefficients (intercept and slope) coef = data.frame(cbind(st=c(1:5),b = runif(5,0.3,5

Re: [R] Trying to avoid loop structure

2010-09-29 Thread Phil Spector
Mathieu - First of all, you can combine as many conditions as you want in an if statement, using && (and) and || (or). So to say coef$st[i-1] < obs[t] < coef$st[i] use coef$st[i-1] < obs[t] && obs[t] < coef$st[i] So following your logic, you could use x = numeric(length(obs)) for(t

Re: [R] A problem with plotting a long expression in ylab ?

2010-09-29 Thread Paul Murrell
Hi On 29/09/2010 8:17 p.m., Tal Galili wrote: My honor. A short question: if there is something in the device that is sensitive to the overlapping of the text, then is it possible to add a warning massage output when the length of the text is longer then the device dimensions? The graphics en

[R] Understanding linear contrasts in Anova using R

2010-09-29 Thread David Howell
#I am trying to understand how R fits models for contrasts in a #simple one-way anova. This is an example, I am not stupid enough to want #to simultaneously apply all of these contrasts to real data. With a few #exceptions, the tests that I would compute by hand (or by other software) #will give

[R] Hashing a set

2010-09-29 Thread Lorenzo Isella
Dear All, I am given a time series such at, at every time t_i, I am given a set of data (every element of the set is just an integer number). What I need is an injective function able to map every set into a number (possibly an integer number, but that is not engraved in the stone). Does anybody kn

[R] fitting model to resampled data

2010-09-29 Thread Michael Larkin
I apologize if this comes across as confusing. I will try to explain my situation as best I can. I have R bootstrapping my growth data for fish. It's resampling my database of age and length data and then produces several new datasets for me. In this case, it's resampling my data to create

  1   2   >