[R] Interpreting Logistic Regression

2008-08-20 Thread Madhavi Bhave
Hi ! This is Madhavi from Mumbai, India. Incidently this is my first post. I am working on Credit Scoring Model and using R, I have run the logistic regression. I have received following Output. I have two questions (a) What is the significance of "family = binomial(link = logit)". Why do I

[R] Help Regarding 'integrate'

2008-08-20 Thread A
I have an R function defined as: f<-function(x){ return(dchisq(x,9,77)*((13.5/x)^5)*exp(-13.5/x)) } Numerically integrating this function, I observed a couple of things: A) Integrating the function f over the entire positive real line gives an error: > integrate(f,0,Inf) Error in integrate(f,

[R] Windows Vista, Rterm & LeftAlt + Tab issue

2008-08-20 Thread Henrik Bengtsson
Hi, my Rterm does not longer take key presses after I have pressed Left Alt+Tab in order to switch away from an active Rterm window. I have found a way to get Rterm to "respond" again. I basically have to kill the process. This occurs on a fresh Windows Vista Business 32-bit installation (with

Re: [R] vector operation using regexpr?

2008-08-20 Thread markleeds
Hi John: I didn't realize that that was your problem. You can make it work for any number of rows by putting it in lapply as below. I'm sorry for the misunderstanding. I'll send to the list also since I guess my last solution was kind of bad now that I understand what you want. DF <- data.fr

Re: [R] vector operation using regexpr?

2008-08-20 Thread Charles C. Berry
On Wed, 20 Aug 2008, John Christie wrote: Hi, Here's my problem... I have a data frame with three columns containing strings. The first columns is a simple character. I want to get the index of that character in the second column and use it to extract the item from the third column. I can

Re: [R] Reading in a value of .Random.seed in .Rprofile

2008-08-20 Thread Rolf Turner
On 21/08/2008, at 3:24 PM, Charles C. Berry wrote: On Thu, 21 Aug 2008, Rolf Turner wrote: But why does this happen on *my* system, and not on Chuck's??? Because I goofed by rerunning ALL the lines in .Rprofile rather than just the last two. When I run just the last tw

Re: [R] Advice requested: Best method of coding "time since" repeating event

2008-08-20 Thread Gabor Grothendieck
Without some data we can't tell precisely the setup but here it is using Date class and you can adapt it to your specific situation. We first define functions to get the prior wed (or the same day if its wed) and the last day of the prior month. Then we define the test data e of event dates and d

Re: [R] Reading in a value of .Random.seed in .Rprofile

2008-08-20 Thread Charles C. Berry
On Thu, 21 Aug 2008, Rolf Turner wrote: On 21/08/2008, at 10:21 AM, Charles C. Berry wrote: On Thu, 21 Aug 2008, Rolf Turner wrote: > > > For reasons that are best known to myself [ ;-) ] I have a value of > .Random.seed > saved (via dput()) in a file ``.Random.seed.save''. > > In my .R

Re: [R] vector operation using regexpr?

2008-08-20 Thread markleeds
Hi: I think you want regexpr so below does what you want but it doesn't handle the case when L isn't in the second column. I'm still trying to figure that out but don't count on it. Hopefully someone else will reply with that piece. DF <- data.frame(col1="L",col2="MAIL",col3="PLOY") print(DF)

[R] GAM-binomial logit link

2008-08-20 Thread Marina Laborde
Dear all, I'm using a binomial distribution with a logit link function to fit a GAM model. I have 2 questions about it. First i am not sure if i've chosen the most adequate distribution. I don't have presence/absence data (0/1) but I do have a rate which values vary between 0 and 1. This means

[R] vector operation using regexpr?

2008-08-20 Thread John Christie
Hi, Here's my problem... I have a data frame with three columns containing strings. The first columns is a simple character. I want to get the index of that character in the second column and use it to extract the item from the third column. I can do this using a scalar method. But I'm

[R] Advice requested: Best method of coding "time since" repeating event

2008-08-20 Thread M-J S Milloy
Hello, I have a dataset containing approx 1000 events spanning four years (2004.03 to 2008.07). For each event, I'd like to determine the time (in minutes) since the most recent final Wednesday of the month. I've found no obvious solution on the list or online; I think I'll try to use function

Re: [R] How to solve this problem ?

2008-08-20 Thread Daren Tan
Small progress, I am relying on levene test to check for equality of variances. Is my understanding correct, the larger the p-value, the more likely the variances are the same ? > trt [1] 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 4 4 4 4 4 Levels: 1 2 3 4 > levene.test(rep(rnorm(5), 4), trt, option="media

Re: [R] data.frame() creates list?

2008-08-20 Thread Bill.Venables
Data frames *are* lists. They just have a guaranteed structure and a different class, but they may be used interchangably with lists nearly everywhere. Try class(ByEBNum) for a more relevant check of what kind of object you have. Bill Venables http://www.cmis.csiro.au/bill.venables/ -

Re: [R] Reading in a value of .Random.seed in .Rprofile

2008-08-20 Thread Ray Brownrigg
Hi Rolf: I think this is a case of RTFM. ?.Rprofile tells you that the profile is executed before the workspace is restored. Initially I thought this might be similar to bug PR#12567 that I filed this week, but now I think not necessarily. Cheers, Ray On Thu, 21 Aug 2008, Rolf Turner wrote

Re: [R] data.frame() creates list?

2008-08-20 Thread Henrik Bengtsson
It is a data.frame. They are represented by lists. df <- data.frame(a=1:2, b=letters[1:2]); > str(df) 'data.frame': 2 obs. of 2 variables: $ a: int 1 2 $ b: Factor w/ 2 levels "a","b": 1 2 > class(df); [1] "data.frame" > mode(df); [1] "list" > typeof(df); [1] "list" For details, see code,

[R] pnmath compilation failure; dylib issue?

2008-08-20 Thread Eric Rupley
(1) ...need to speed up a monte-carlo sampling...any suggestions about how I can get R to use all 8 cores of a mac pro would be most useful and very appreciated... (2) spent the last few hours trying to get pnmath to compile under os- x 10.5.4... using gcc version 4.2.1 (Apple Inc. bui

[R] data.frame() creates list?

2008-08-20 Thread Farley, Robert
I obviously don't know what I'm doing. I want to create "ByEBNum" as a data frame, but it comes out as a list. How do I make it a data frame? > EBNumStn <- c(673.65, 800, 1000, 1000, 800, 700, 600, 500, 400, 200, 50, 50 ) > ByEBNum <- data.frame(c(1:12),EBNumStn) > typeof(EBNumSt

Re: [R] Extracting eg A[, , 3, 1, ] from an array but using dimension names and levels

2008-08-20 Thread Gabor Grothendieck
Try this: do.call("[", c(list(HairEyeColor), list(TRUE, 3, 1))) On Wed, Aug 20, 2008 at 7:16 PM, Søren Højsgaard <[EMAIL PROTECTED]> wrote: > Consider the extraction > >> HairEyeColor[,3,1] > Black Brown Red Blond > 1025 7 5 > > Suppose I have the appropriate dimensions and levels

[R] Extracting eg A[, , 3, 1, ] from an array but using dimension names and levels

2008-08-20 Thread Søren Højsgaard
Consider the extraction > HairEyeColor[,3,1] Black Brown Red Blond 1025 7 5 Suppose I have the appropriate dimensions and levels given as variables, e.g. d1 <-2 l1 <-3 d2 <-3 l2 <-1 How can I then make the "extraction" above using d1, l1, d2, l2 (for an array of arbitrary

[R] GAM_binomial logit link

2008-08-20 Thread Marina Laborde
Dear all,   I'm using a binomial distribution with a logit link function to fit a GAM model. I have 2 questions about it. First i am not sure if i've chosen the most adequate distribution. I don't have presence/absence data (0/1) but I do have a rate which values vary between 0 and 1. This means

Re: [R] Reading in a value of .Random.seed in .Rprofile

2008-08-20 Thread Rolf Turner
On 21/08/2008, at 10:21 AM, Charles C. Berry wrote: On Thu, 21 Aug 2008, Rolf Turner wrote: For reasons that are best known to myself [ ;-) ] I have a value of .Random.seed saved (via dput()) in a file ``.Random.seed.save''. In my .Rprofile I have the lines: .Random.seed <- dget(".Rand

Re: [R] Reading in a value of .Random.seed in .Rprofile

2008-08-20 Thread Charles C. Berry
On Thu, 21 Aug 2008, Rolf Turner wrote: For reasons that are best known to myself [ ;-) ] I have a value of .Random.seed saved (via dput()) in a file ``.Random.seed.save''. In my .Rprofile I have the lines: .Random.seed <- dget(".Random.seed.save") Junk <- dget(".Random.seed.save") print(a

[R] Reading in a value of .Random.seed in .Rprofile

2008-08-20 Thread Rolf Turner
For reasons that are best known to myself [ ;-) ] I have a value of .Random.seed saved (via dput()) in a file ``.Random.seed.save''. In my .Rprofile I have the lines: .Random.seed <- dget(".Random.seed.save") Junk <- dget(".Random.seed.save") print(all.equal(.Random.seed,dget(".Random.seed.

Re: [R] Positioning of axis titles

2008-08-20 Thread Greg Snow
You could also include the call to title/mtext in the plot.axes argument to filled.contour, then the coordinate system is still correct. Hope this helps, -- Gregory (Greg) L. Snow Ph.D. Statistical Data Center Intermountain Healthcare [EMAIL PROTECTED] (801) 408-8111 > -Original Message--

Re: [R] Confidence Interval

2008-08-20 Thread Raphael Saldanha
Hi! Here is a better code, using the percentil value instead the position, and some corrections on the graph code. The reason in the difference on the tails is elementar, but I don't had see it before. The right and left limits are calculated by simulation, and his differences from the mean are n

Re: [R] R-Embedding and error messages

2008-08-20 Thread Jorge Cardoso
I tried both solutions but I always get "undefined symbol" when executing I have checked my Makefile and I'm sure that -lR is present when compiling I did a grep for the R-sources and verified that both functions exists I will try to post it in r-devel list. Thank for yours responses dear Mar

Re: [R] Looping over groups

2008-08-20 Thread Dylan Beaudette
On Wednesday 20 August 2008, Josh B wrote: > > Works for me: > > x <- read.csv('christina.txt') > > > > x.list <- by(x, x$gen, function(d) { > > d.clean <- d[,-1] > > cov(d.clean, y= NULL, use= "complete.obs", method="pearson") > > } ) > > > >note that the output is a list, where each element corre

Re: [R] Positioning of axis titles

2008-08-20 Thread Prof Brian Ripley
On Wed, 20 Aug 2008, Nicky Chorley wrote: 2008/8/20 Uwe Ligges <[EMAIL PROTECTED]>: Increase the margins as well, default is: par("mar"=c(5,4,4,1)+.1) Uwe Ligges Thanks very much. One further question: is it possible to change the position of only one axis title (since using mgp changes bo

Re: [R] Problems with PostScript Encoding

2008-08-20 Thread Prof Brian Ripley
Please read the posting guide and supply the information asked for and the minimal reproducible example asked for. I suspect the issue is how you selected 'alpha', but another issue is if you mean the mathematical symbol alpha or the Greek letter alpha, for the solution is different in the two

Re: [R] Looping over groups

2008-08-20 Thread Josh B
> Works for me: > x <- read.csv('christina.txt') > > x.list <- by(x, x$gen, function(d) { > d.clean <- d[,-1] > cov(d.clean, y= NULL, use= "complete.obs", method="pearson") > } ) > >note that the output is a list, where each element corresponds to one >level of 'gen'. if you need to write each elem

Re: [R] read.csv : double quoted numbers

2008-08-20 Thread Gabor Grothendieck
The problem is the commas, not the quotes: > Lines.raw <- '"1,001.23""1,008,000.456"' > Lines <- readLines(textConnection(Lines.raw)) > Lines <- gsub(",", "", Lines) > read.table(textConnection(Lines)) V1 V2 1 1001.23 1008000 On Wed, Aug 20, 2008 at 2:27 PM, Aval Sarri <[EMAIL PROTE

Re: [R] Quantile regression with complex survey data

2008-08-20 Thread Stas Kolenikov
On Wed, Aug 20, 2008 at 8:12 AM, Cheng, Yiling (CDC/CCHP/NCCDPHP) <[EMAIL PROTECTED]> wrote: > I am working on the NHANES survey data, and want to apply quantile > regression on these complex survey data. Does anyone know how to do > this? There are no references in technical literature (thinking,

Re: [R] Positioning of axis titles

2008-08-20 Thread Greg Snow
A couple of things to try: Some adjustment can be made by adding whitespace to your label, e.g.: > plot(1:10, xlab='test') > plot(1:10, xlab='test\n') > plot(1:10, xlab='test \n') You can set the label to be blank originally (xlab=''), then add it afterwards using title, mtext, or text; but

Re: [R] Positioning of axis titles

2008-08-20 Thread Prof Brian Ripley
On Wed, 20 Aug 2008, Uwe Ligges wrote: Nicky Chorley wrote: Hi, I have created a plot using filled.contour() and have the problem that one of the axis titles and an axis label are overlapping. I have tried changing par()$mgp (with, e.g. par(mgp=c(4,1,0)) ), but this just makes the title go o

Re: [R] Line of best

2008-08-20 Thread Ling, Gary (Electronic Trading)
See: ?loess or ?lowess -gary -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Altaweel, Mark R. Sent: Wednesday, August 20, 2008 12:54 PM To: r-help@r-project.org Subject: [R] Line of best Hi, I have a scatter plot, with an equation that best fits the

Re: [R] Removing

2008-08-20 Thread Henrique Dallazuanna
Try this also: Dt <- cbind(Age[o],Sex[o],Ill[o]) subset(as.data.frame(Dt), V3 != "No") On Wed, Aug 20, 2008 at 3:24 PM, <[EMAIL PROTECTED]> wrote: > I think I should be clearer. Given the matrix of column vectors Age, Sex, > and Ill > > Age=c(11,52,65,59,13,63,70,40,15,33,65,38,62,10,25,32,62,

[R] Removing

2008-08-20 Thread bad2101
Thanks so much for the help! Brian __ 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, reproducib

[R] Problems with PostScript Encoding

2008-08-20 Thread FScottDahlgren
Hello all, I suspect my problem is not new: I am having difficulty getting an alpha character to print in a PostScript file made by R graphics (in my legend). At first, I figured out how to actually get the character on the screen; however, when I saved the graphic to a PostScript file the alph

[R] Quantile regression with complex survey data

2008-08-20 Thread Cheng, Yiling (CDC/CCHP/NCCDPHP)
> Dear there, > > I am working on the NHANES survey data, and want to apply quantile > regression on these complex survey data. Does anyone know how to do > this? > > Thank you in advance, > Yiling Cheng > Yiling J. Cheng MD, PhD > Epidemiologist > CoCHP, Division of Diabetes Translation > Cente

Re: [R] Removing

2008-08-20 Thread Jorge Ivan Velez
I'm sorry Brian, my bad. Last line should be yourdata[yourdata[,3]!='No',] HTH, Jorge On Wed, Aug 20, 2008 at 2:29 PM, Jorge Ivan Velez <[EMAIL PROTECTED]>wrote: > > Hi Brian, > > It's almost the same. Try this: > > yourdata=cbind(Age,Sex,Ill) # Age, Sex and Ill are the variables in your

[R] Support Vector Machines

2008-08-20 Thread excalibur
Hi, i try to use function svm of package e1071 to estimate a density. But if my data are X=(X1,...,Xn) and m<-svm(X) some values of m$SV are less than 0. I don't see how i can get the estimation of the density with this function. Thanks for your help. Rémi -- View this message in context: htt

[R] Quantile regression with complex survey data

2008-08-20 Thread Cheng, Yiling (CDC/CCHP/NCCDPHP)
Dear there, I am working on the NHANES survey data, and want to apply quantile regression on these complex survey data. Does anyone know how to do this? Thank you in advance, Yiling Cheng Yiling J. Cheng MD, PhD Epidemiologist CoCHP, Division of Diabetes Translation Centers for Disease Control an

Re: [R] Positioning of axis titles

2008-08-20 Thread Nicky Chorley
2008/8/20 Uwe Ligges <[EMAIL PROTECTED]>: > Increase the margins as well, default is: > par("mar"=c(5,4,4,1)+.1) > > Uwe Ligges > Thanks very much. One further question: is it possible to change the position of only one axis title (since using mgp changes both)? Thanks again, Nicky Chorley ___

Re: [R] Removing

2008-08-20 Thread Jorge Ivan Velez
Hi Brian, It's almost the same. Try this: yourdata=cbind(Age,Sex,Ill) # Age, Sex and Ill are the variables in your post :) yourdata[yourdata[,3]=='Yes',] #or yourdata[yourdata[,3]!='Yes',] HTH, Jorge On Wed, Aug 20, 2008 at 2:24 PM, <[EMAIL PROTECTED]> wrote: > I think I should be

[R] read.csv : double quoted numbers

2008-08-20 Thread Aval Sarri
Hello; I am new user of R; so pardon me. I am reading a .txt file that has around 50+ numeric columns with '\t' as separator. I am using read.csv function along with colClasses but that fails to recognize double quoted numeric values. (My numeric values are something like "1,001.23"; "1,008,000.4

Re: [R] R-Embedding and error messages

2008-08-20 Thread Luke Tierney
On Wed, 20 Aug 2008, Martin Morgan wrote: Hi Jorge -- I hesitate to suggest this unsupported solution (as these public suggestions tend to mean that the solution disappears!), but in C Don't use this -- it is subject to change/removal with no notice. I do not believe there is a C level metha

[R] Removing

2008-08-20 Thread bad2101
I think I should be clearer. Given the matrix of column vectors Age, Sex, and Ill Age=c(11,52,65,59,13,63,70,40,15,33,65,38,62,10,25,32,62,36,11,33,13,7,64,3,65,59,15,62,37,17,35,15,50,40,35,35,36,57,16,68,54,77,72,58,20,17,62,20,52,9,50,8,35,48,25,11,74,12,44,53,37,24,69,7,17,8,11,17,36,21,60

Re: [R] Removing

2008-08-20 Thread Jorge Ivan Velez
Hi Brian, Try Ill[Ill!='No'] #or Ill[Ill=='Yes'] HTH, Jorge On Wed, Aug 20, 2008 at 2:16 PM, <[EMAIL PROTECTED]> wrote: > I'm trying to remove the elements "No" from the character vector > > > Ill=c("No","Yes","Yes","Yes","No","Yes","Yes","Yes","Yes","Yes","No","No","No","Yes","No","Yes"

Re: [R] Removing

2008-08-20 Thread Henrique Dallazuanna
Try this: Ill[Ill != "No"] On Wed, Aug 20, 2008 at 3:16 PM, <[EMAIL PROTECTED]> wrote: > I'm trying to remove the elements "No" from the character vector > > Ill=c("No","Yes","Yes","Yes","No","Yes","Yes","Yes","Yes","Yes","No","No","No","Yes","No","Yes","Yes","Yes","No","Yes","Yes","Yes","No","Y

[R] Removing

2008-08-20 Thread bad2101
I'm trying to remove the elements "No" from the character vector Ill=c("No","Yes","Yes","Yes","No","Yes","Yes","Yes","Yes","Yes","No","No","No","Yes","No","Yes","Yes","Yes","No","Yes","Yes","Yes","No","Yes","No","Yes","Yes","No","Yes","No","Yes","Yes","Yes","No","No","Yes","No","Yes","Yes","Yes",

Re: [R] nonlinear constrained optimization

2008-08-20 Thread Paul Smith
On Tue, Aug 19, 2008 at 8:12 PM, Hans W. Borchers <[EMAIL PROTECTED]> wrote: > Please have a look at the 'Rdonlp2' package at . > It provides non-linear optimization with nonlinear constraints. Notwithstanding, be aware of the following limitation of Donlp2: "If the pr

Re: [R] FYI: APL in R

2008-08-20 Thread Emmanuel Charpentier
Le mardi 19 août 2008 à 23:52 -0700, Jan de Leeuw a écrit : > http://idisk.mac.com/jdeleeuw-Public/utilities/apl/apl.R Thank you ! I was beginning to think I was the last of the dinosaurs... ISTR that someone else on the list is also an (un)repentant APLer... > Although this is all prefix and no

Re: [R] How to send Html using SQL Server db mail

2008-08-20 Thread Barry Rowlingson
2008/8/20 Bos, Roger <[EMAIL PROTECTED]>: > All, > > I have a variable called `go` and it has a single quote in the name > column of line 47 that I am trying to get rid of. I have tried using > gsub, but I cannot get the syntax correct to tell R to remove the ' > (single quote). > >> go[47,] >

Re: [R] Positioning of axis titles

2008-08-20 Thread Uwe Ligges
Nicky Chorley wrote: Hi, I have created a plot using filled.contour() and have the problem that one of the axis titles and an axis label are overlapping. I have tried changing par()$mgp (with, e.g. par(mgp=c(4,1,0)) ), but this just makes the title go off the screen. I can't work out how to ma

Re: [R] Line of best

2008-08-20 Thread Ben Bolker
Altaweel, Mark R. anl.gov> writes: > I have a scatter plot, with an equation that best fits the scatter plot expressed as: 1/x^.6. I know for > normal linear regression lines you can use the abline() command; however, since my best fit line is not > linear, how can I draw my line on the scatt

Re: [R] R-Embedding and error messages

2008-08-20 Thread Martin Morgan
Hi Jorge -- I hesitate to suggest this unsupported solution (as these public suggestions tend to mean that the solution disappears!), but in C extern void R_SetErrorHook(void (*)(SEXP, char *)); void my_ErrorHook(SEXP call, char *message) { /* etc; e.g., cache message, perhaps reset

[R] Positioning of axis titles

2008-08-20 Thread Nicky Chorley
Hi, I have created a plot using filled.contour() and have the problem that one of the axis titles and an axis label are overlapping. I have tried changing par()$mgp (with, e.g. par(mgp=c(4,1,0)) ), but this just makes the title go off the screen. I can't work out how to make the plot take up less

Re: [R] Survey Design / Rake questions

2008-08-20 Thread Farley, Robert
Thank you for your help. Yes, my problem is one of non-response. We try to hand a survey form to everyone that boards at each stop, but we're getting only ~10% usable responses. One reason is that the "full survey" is long, and requires geo-locating 2 points - Trip Origin and Destination. M

Re: [R] Writing Rcmdr Plugins

2008-08-20 Thread G. Jay Kerns
...[snipped] > > The /inst directory: in here you will need to put a file "menus.txt" > This should have been "the /inst/etc" directory, as you noted in your original post. Jay __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/list

[R] Line of best

2008-08-20 Thread Altaweel, Mark R.
Hi, I have a scatter plot, with an equation that best fits the scatter plot expressed as: 1/x^.6. I know for normal linear regression lines you can use the abline() command; however, since my best fit line is not linear, how can I draw my line on the scatter plot in a similar fashion to ablin

Re: [R] Writing Rcmdr Plugins

2008-08-20 Thread G. Jay Kerns
Dear Irina, On Wed, Aug 20, 2008 at 12:02 PM, Irina Ursachi <[EMAIL PROTECTED]> wrote: > Dear all, > > I am trying to write a plugin for the RCommander and having troubles > understanding how to actually do that. I have read Mr. Fox's tutorial > about writing Rcmdr plugins and though it seems

Re: [R] Simple estimate of a probability by simulation (sender)

2008-08-20 Thread Van Wyk, Jaap
Thank you for all the responses! It turned out that my "theory" contained an error - the answer is 0.2544, and this was confirmed with the simulation in R. My students will be impressed - and I will quote where I found the great help. Regards Jacob Jacob L van Wyk Dept of Statistics Univer

Re: [R] Lattice: problem using panel.superpose and panel.groups

2008-08-20 Thread Emmanuel Charpentier
Le dimanche 17 août 2008 à 09:36 +, Dieter Menne a écrit : [ Snip .. ] > Trellis graphics are a bit like hash functions: you can be close to the > target, but get a far-off result. Nice candidate for a fortune() entry ... Emmanuel Charpentier ___

Re: [R] Writing Rcmdr Plugins

2008-08-20 Thread stephen sefick
Session info- what type of computer-etc. On Wed, Aug 20, 2008 at 12:02 PM, Irina Ursachi <[EMAIL PROTECTED]> wrote: > Dear all, > > I am trying to write a plugin for the RCommander and having troubles > understanding how to actually do that. I have read Mr. Fox's tutorial > about writing Rcmdr plu

[R] How to send Html using SQL Server db mail

2008-08-20 Thread Bos, Roger
All, I have a variable called `go` and it has a single quote in the name column of line 47 that I am trying to get rid of. I have tried using gsub, but I cannot get the syntax correct to tell R to remove the ' (single quote). > go[47,] gvkey SymbolName Rank MarketCap

Re: [R] Looping over groups

2008-08-20 Thread Dylan Beaudette
2008/8/20 Josh B <[EMAIL PROTECTED]>: > Here is my underlying data file. Of course, please don't feel obliged to > spend any more time on this! > > > - Original Message > From: Dylan Beaudette <[EMAIL PROTECTED]> > To: Josh B <[EMAIL PROTECTED]> > Cc: r-help@r-project.org > Sent: Wednesda

[R] Writing Rcmdr Plugins

2008-08-20 Thread Irina Ursachi
Dear all, I am trying to write a plugin for the RCommander and having troubles understanding how to actually do that. I have read Mr. Fox's tutorial about writing Rcmdr plugins and though it seems to me that some steps are missing. I would like to know, whether there are some Commands which g

Re: [R] Simple estimate of a probability by simulation

2008-08-20 Thread davidr
I get 5/36 + log(2)/6, not 1/9. David L. Reiner, PhD Head Quant Rho Trading Securities, LLC -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Alberto Monteiro Sent: Wednesday, August 20, 2008 7:56 AM To: Van Wyk, Jaap; r-help@r-project.org Subject: Re: [R]

Re: [R] Looping over groups

2008-08-20 Thread Josh B
When I try your suggestion, I get the output, e.g.,: christina.df$gen: 309 NULL Returned for each vector. That doesn't seem good (I associate "NULL" with something being empty), but perhaps I am misinterpreting it? - Original Message From: Dylan Beaudette <[EMAIL PROTECTED]> To: Josh

Re: [R] Looping over groups

2008-08-20 Thread Peter Dalgaard
Dylan Beaudette wrote: > On Wed, Aug 20, 2008 at 7:48 AM, Josh B <[EMAIL PROTECTED]> wrote: > >> Hello, >> >> My R skills are somewhere between novice and intermediary, and I am hoping >> that some of you very helpful forum members, whom I've seen work your magic >> on other peoples' problems/

Re: [R] Confidence Interval

2008-08-20 Thread Raphael Saldanha
Thanks Professor and Bernardo, What I'm trying to do is this: I have a macro for Minitab. His author says it's a "Monte Carlo simulation to estimate a confidence interval". But and don't have Minitab, don't like to work with illegal licenses, and LOVE R. So, I re-write the macro in a R script. Be

Re: [R] Looping over groups

2008-08-20 Thread Dylan Beaudette
On Wed, Aug 20, 2008 at 7:48 AM, Josh B <[EMAIL PROTECTED]> wrote: > Hello, > > My R skills are somewhere between novice and intermediary, and I am hoping > that some of you very helpful forum members, whom I've seen work your magic > on other peoples' problems/questions, can help me here. > > I

[R] R-Embedding and error messages

2008-08-20 Thread Jorge W. Cardoso
I'm writing a C++ application using R-embedding to do some forecast process. I also use R_tryEval instead of R_Eval to run my R-script, so that in case of error I know exactly in which line number was the last error. In particular, from time in time y get some error messages refering an exception

[R] Looping over groups

2008-08-20 Thread Josh B
Hello, My R skills are somewhere between novice and intermediary, and I am hoping that some of you very helpful forum members, whom I've seen work your magic on other peoples' problems/questions, can help me here. I have a matrix with the following format: (i) individual plants comprising many

Re: [R] nonlinear constrained optimization

2008-08-20 Thread Paul Smith
On Tue, Aug 19, 2008 at 7:37 PM, Ravi Varadhan <[EMAIL PROTECTED]> wrote: > The "Tango project" website (from Brazil) has some R functions to implement > Algencan. I haven't used it, but I would be interested to hear others' > experience if someone has already used it or will be using it. Ravi,

Re: [R] arma: what is the meaning of Pr(>|t|)?

2008-08-20 Thread Prof Brian Ripley
On Wed, 20 Aug 2008, Prof Brian Ripley wrote: On Wed, 20 Aug 2008, Alberto Monteiro wrote: In the summary of the output of arma, there's a number Pr(>|t|), however, I don't know what is its meaning - at least, it doesn't _seem_ to be a Student's t distribution. It is using asymptotic normali

Re: [R] arma: what is the meaning of Pr(>|t|)?

2008-08-20 Thread Prof Brian Ripley
On Wed, 20 Aug 2008, Alberto Monteiro wrote: In the summary of the output of arma, there's a number Pr(>|t|), however, I don't know what is its meaning - at least, it doesn't _seem_ to be a Student's t distribution. It is using asymptotic normality. There is no exact theory. Who mentioned S

Re: [R] Survey Design / Rake questions

2008-08-20 Thread Stas Kolenikov
On Mon, Aug 18, 2008 at 6:18 PM, Farley, Robert <[EMAIL PROTECTED]> wrote: > My motivation is to try to correct for a "time on board" bias we see in > our surveys. Not surprisingly, riders who are only on board a short > time don't attempt/finish our survey forms. We're able to weight our > surve

Re: [R] Simple estimate of a probability by simulation

2008-08-20 Thread hadley wickham
On Wed, Aug 20, 2008 at 7:56 AM, Alberto Monteiro <[EMAIL PROTECTED]> wrote: > > Jaap Van Wyk wrote: >> >> I would appreciate any help with the following. >> Problem: Suppose A, B and C are independent U(0,1) random variables. >> What is the probability that A(x^2) + Bx + C has real roots? I have >

Re: [R] Simple estimate of a probability by simulation

2008-08-20 Thread N'DOYE Souleymane
Greetings, Let me present my modest proposition as function with an input and an output, it is based on the valuable solution of Alberto Monteiro. I have choosen delta superior or equal to 0 wich still provide a REAL solution : prob <- function(n){ a <- runif(n) b <- runif(n) c <- runif(n) delta

[R] How to solve this problem ?

2008-08-20 Thread Daren Tan
I have disabled html text editing mode, thanks to Prof. Ripley for the kind reminder. Given three geological devices that takes 5 readings at 4 environmental conditions (A to D). What will be the proper approach to select the most reliable device ? m1 <- c(73,52,49,53,83,43,58,94,53,62,75,6

Re: [R] arma: what is the meaning of Pr(>|t|)?

2008-08-20 Thread Peter Dalgaard
Alberto Monteiro wrote: > In the summary of the output of arma, there's a number Pr(>|t|), however, I > don't know what is its meaning - at least, it doesn't _seem_ to be a > Student's t distribution. > > Reproducible test case: > x <- c(0.5, sin(1:9)) > reg <- arma(x, c(1,0)) > summary(reg

Re: [R] Simple estimate of a probability by simulation

2008-08-20 Thread Alberto Monteiro
Jaap Van Wyk wrote: > > I would appreciate any help with the following. > Problem: Suppose A, B and C are independent U(0,1) random variables. > What is the probability that A(x^2) + Bx + C has real roots? I have > done the theoretical work and obtained an answer of 1/9 = 0.. > Now I want

Re: [R] bug in lme4?

2008-08-20 Thread Renaud Lancelot
Thank you very much ! Renaud 2008/8/20 Peter Dalgaard <[EMAIL PROTECTED]> > Renaud Lancelot wrote: > > Dear all, > > > > As the maintener of package aod, I thank you for bringing my attention on > > this problem. I will try to alter the code in aod. However, I am not sure > to > > be able to do

[R] Simple estimate of a probability by simulation

2008-08-20 Thread Van Wyk, Jaap
Hallo I would appreciate any help with the following. Problem: Suppose A, B and C are independent U(0,1) random variables. What is the probability that A(x^2) + Bx + C has real roots? I have done the theoretical work and obtained an answer of 1/9 = 0.. Now I want to show my students to get

[R] arma: what is the meaning of Pr(>|t|)?

2008-08-20 Thread Alberto Monteiro
In the summary of the output of arma, there's a number Pr(>|t|), however, I don't know what is its meaning - at least, it doesn't _seem_ to be a Student's t distribution. Reproducible test case: x <- c(0.5, sin(1:9)) reg <- arma(x, c(1,0)) summary(reg) Call: arma(x = x, order = c(1, 0))

Re: [R] Time Series w/irregular frequency, how to construct a time series object?

2008-08-20 Thread Gabor Grothendieck
The zoo package can represent irregular time series. On Wed, Aug 20, 2008 at 4:41 AM, Marco Leandro Carmosino <[EMAIL PROTECTED]> wrote: > Hello, > > I am having trouble constructing a time series object for my data. This is > because the frequency is irregular: one year, there may be only 100 > i

[R] How to concatenate values from a time series and a forecast

2008-08-20 Thread Lane, Jim
Hi, All I have a time series object: o1ts Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec 2005 56 58 67 68 69 71 78 78 2006 84 83 86 97 103 123 120 134 131 127 135 137 2007 142 138 141 151 155 173 181 188 195 191 262 273 2008 283 295 311 327 334 340 361 And

Re: [R] pdf filenames in while loop

2008-08-20 Thread Barry Rowlingson
2008/8/20 Wesley Roberts <[EMAIL PROTECTED]>: > Dear R users, > pdf(file="as.character(paste(f.mat[a])).pdf") Whoa! Why the quotes? And why the as.character? Just paste: pdf(file=paste(f.mat[a],".pdf",sep="")) should do it. It looks like you were trying to create a file called "as.character(.

[R] centroid of radial.plot differs from centroid.polygon

2008-08-20 Thread Stefan Uhmann
Dear R-Helpers, I need the centroid of circular data and (because the function used does not provide the centroid coordinates, or did I miss sth.?) tried it via the indirect way and just computed the cartesian coordinates: >>> library(plotrix) library(maps) #generate data data1<-matrix(c(1.8

[R] Switch from [EMAIL PROTECTED] to [EMAIL PROTECTED]

2008-08-20 Thread N'DOYE Souleymane
Dear all, My email address has changed today to [EMAIL PROTECTED] Best regards, Souleymane [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] spatial probit/logit for prediction

2008-08-20 Thread Roger Bivand
Freeman, Robert emcc.edu> writes: > I am wondering if there is a way to do a spatial error probit/logit > model in R? I can't seem to find it in any of > the packages. I can do it in MATLAB with Gibbs sampling, but would > like to confirm the results. Ideally I > would like to use this model

Re: [R] converting coordinates from utm to longitude / latitude

2008-08-20 Thread Werner Wernersen
I forgot one more potentially time-saving hint if someone else wants to use org2org for such a conversion: I found that only GDAL for Windows 1.4.4 works together with the proj.dll file which is downloadable from proj.4 but version 1.5 does not. - Ursprüngliche Mail Von: Dylan Beaud

Re: [R] spatial probit/logit for prediction

2008-08-20 Thread Torsten Hothorn
Hi Robb, the gamboost() function in package `mboost' may help. The details are described in @article{Kneib+Hothorn+Tutz:2009, author = {Thomas Kneib and Torsten Hothorn and Gerhard Tutz}, title = {Variable Selection and Model Choice in Geoadditive Regression Models}, journal = {Biometric

[R] pdf filenames in while loop

2008-08-20 Thread Wesley Roberts
Dear R users, I am a remote sensing researcher currently studying the use of LiDAR data for quantifying tree height, in particular I would like to determine the sample size needed to capture and quantify canopy height variability. To do this I have employed the use of automap(), which automatic

Re: [R] address (nil), cause 'memory not mapped'

2008-08-20 Thread Roger Bivand
Juan Manuel Barreneche gmail.com> writes: > > just to mention that the loop was already running for about 20 hours... > > Juan > > On Tue, Aug 19, 2008 at 6:31 PM, Juan Manuel Barreneche > gmail.com>wrote: > > > Dear users, > > I got this problem and i don't have a clue of what it could be h

Re: [R] Writing R Extensions : A new R package for Gini Index decomposition to prupose

2008-08-20 Thread Ndoye Souleymane
Greetings, I have implemented the Gini Decomposition by groups. This programme works for two groups it provides: Gini Between Intergoup, Gini Net Intergoup, and Transvariation Intergroup. Regards, Souleymane > Date: Tue, 19 Aug 2008 19:33:30 -0500> From: [EMAIL PROTECTED]> To: [EMAIL > P

Re: [R] Writing R Extensions : A new R package for Gini Index decomposition to prupose

2008-08-20 Thread Ndoye Souleymane
Many thanks for your advice. Regards, Souleymane> Date: Tue, 19 Aug 2008 09:42:30 -0400> From: [EMAIL PROTECTED]> To: [EMAIL PROTECTED]> Subject: Re: [R] Writing R Extensions : A new R package for Gini Index decomposition to prupose> CC: r-help@r-project.org; [EMAIL PROTECTED]> > See if the

Re: [R] converting coordinates from utm to longitude / latitude

2008-08-20 Thread Werner Wernersen
After having figured out that I had to download the proj.dll file additionally (it would be nice if they actually added a note to their readme) and setting the "+south" parameter, the conversion of the shapfile from UTM to long/lat with the ogr2ogr utility from gdal worked perfectly. Thanks so

  1   2   >