Re: [R] Changing the origin in polar.plot in plotrix package

2007-12-15 Thread hadley wickham
Hi John, One alternative would be to use ggplot2 with a polar coordinate system: library(ggplot2) qplot(mpg, wt, data=mtcars) + coord_polar() qplot(mpg, wt, data=mtcars, ylim=c(3,4)) + coord_polar() etc. You can see more examples of polar coordinates at http://had.co.nz/ggplot2/coord_polar.html

[R] Changing the origin in polar.plot in plotrix package

2007-12-15 Thread John Beamer
I am trying to draw a polar plot, which is easy enough to do in the plotrix package through the polar.plot function. However I would like to change the origin of the length vector. For instance all my length values are between 75 and 85, so instead of having the origin as 0 (the default) I'd like

Re: [R] Analyzing Publications from Pubmed via XML

2007-12-15 Thread Gabor Grothendieck
If we can assume that the abstract is always the 4th paragraph then we can try something like this: library(XML) doc <- xmlTreeParse("http://eutils.ncbi.nlm.nih.gov/entrez/eutils/erss.cgi?rss_guid=0_JYbpsax0ZAAPnOd7nFAX-29fXDpTk5t8M4hx9ytT-";, isURL = TRUE, useInternalNodes = TRUE, trim = TRUE)

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Patrick Connolly
On Fri, 14-Dec-2007 at 08:55PM +0200, Adrian Dusa wrote: |> |> Dear list, |> |> I learned how to connect R to a local MySQL server, using: |> drv <- dbDriver("MySQL") |> con <- dbConnect(drv, user="root", password="mypass", dbname="mydb") |> |> Is it possible to connect R in this way to an exte

[R] Changing the origin in polar.plot in plotrix package

2007-12-15 Thread John Beamer
I am trying to draw a polar plot, which is easy enough to do in the plotrix package through the polar.plot function. However I would like to change the origin of the length vector. For instance all my length values are between 75 and 85, so instead of having the origin as 0 (the default) I'd like

[R] not a package (yet): derivatives of generalized eigen/singular pairs

2007-12-15 Thread Jan de Leeuw
but maybe of use to some: http://gifi.stat.ucla.edu/psychoR/derivatives Computes generalized eigenvalue solutions Ax=\lambda Bx and generalized singular value solutions Rz=\gamma Px and R'x=\gamma Qy for matrices that are differentiable functions of a vector of parameters. Along with the decompos

Re: [R] Analyzing Publications from Pubmed via XML

2007-12-15 Thread David Winsemius
David Winsemius <[EMAIL PROTECTED]> wrote in news:[EMAIL PROTECTED]: > "Farrel Buchinsky" <[EMAIL PROTECTED]> wrote in > news:[EMAIL PROTECTED]: > >> On Dec 13, 2007 11:35 PM, Robert Gentleman <[EMAIL PROTECTED]> >> wrote: >>> or just try looking in the annotate package from Bioconductor >>> >

Re: [R] Rd files with unknown encoding?

2007-12-15 Thread Spencer Graves
Dear Prof. Ripley: Thanks very much. I did as you suggested, which I'll outline here to make it easier for anyone else who might have a similar problem: * Read the offending *.Rd file in R using 'readLines' * Applied 'iconv' to the character vector, following the

[R] [HH] changing font size in interaction2wt

2007-12-15 Thread Patrick Drechsler
Hi, I would like to change font sizes (more generally the cex) in plots produced by the function "interaction2wt" of the "HH" package. Here is an example (from the interaction2wt example) of what I have tried: --8<---cut here---start->8--- rm(list = ls(all = T

Re: [R] train nnet

2007-12-15 Thread Manuel Castejón Limas
Dear Ilh I was planning to dedicate a few hours this christmas to improve the AMORE package. I would like to explore the possibilities of the openMP library and to programm a few more training algorithms. Right now the rbf extension is ready but under testing. I think that what you ask for woul

Re: [R] Using boxplot in a daily time series

2007-12-15 Thread Dylan Beaudette
On Saturday 15 December 2007 07:13:34 am [EMAIL PROTECTED] wrote: > Hi all, > > I'm trying to plot my daily time series, with 3650 observations( 10 years), > with boxplot but I want 12 boxes, one for each month, can anyone help me > doing that. > > Best regards > Sure, there are several approache

Re: [R] Using boxplot in a daily time series

2007-12-15 Thread Domenico Vistocco
From your post it is not clear how the data are organized. Supposing they are in a data frame you could use the ~ sintax. For example: timeColumn=as.Date("01-01-1970") + 1:500 timeSeries=rnorm(500) df=data.frame(time=timeColumn, index=timeSeries) > > head(df) > time index > 1 1-01-20 -

[R] Using boxplot in a daily time series

2007-12-15 Thread pedrosmarques
Hi all, I'm trying to plot my daily time series, with 3650 observations( 10 years), with boxplot but I want 12 boxes, one for each month, can anyone help me doing that. Best regards __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

[R] R memory limits and good memory management

2007-12-15 Thread Chad R. Bhatti
Hello, I am not fluent in computer hardware or software development so I will try to be as precise as I can. I am going to build some R routines to analyze large intraday financial data sets. For this project I think that I need be concerned about R memory limits and good memory management/p

Re: [R] X11 uses font size 25 although 28 was requested

2007-12-15 Thread Peter Dalgaard
Andre Jung wrote: > Hi, > > I'm not sure if the real English warning is the same. I translated it > from German. R came up with the following message: > > --- > Warning message: > In title(main = sinc.exp) : > X11 nutzt Schriftgröße 25 obwohl 28 a

Re: [R] Array dimnames

2007-12-15 Thread Domenico Vistocco
Sorry, there were mistakes in variable names... (I realized only after pressed the send button) Domenico Vistocco wrote: > dave mitchell wrote: > >> Dear all, >> Possibly a rudimentary question, however any help is greatly appreciated. I >> am sorting a large matrix into an array of dim(p(i),

Re: [R] Array dimnames

2007-12-15 Thread Domenico Vistocco
dave mitchell wrote: > Dear all, > Possibly a rudimentary question, however any help is greatly appreciated. I > am sorting a large matrix into an array of dim(p(i),q,3). I put each entry > into a corresponding matrix (1 of the 3) based on some criteria. I figure > this will assist me in condens

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Adrian Dusa
On Saturday 15 December 2007, you wrote: > Use ssh forwarding to forward local port 3307 to remote port 3306 > specifying the remote account and password.  Then if you use local port > 3306 you can access your local version of MySQL and if you > use port 3307 you can access the remote version.   Th

Re: [R] how to add an index to a vignette?

2007-12-15 Thread dankelley
Oh, I see. The answer is just to do as usual, e.g. as follows, and R CMD build simply takes care of it. ... \usepackage{makeidx} \makeindex ... \begin{document} ... \index{something} ... \printindex \end{document} -- View this message in context: http://www.nabble.com/how-to-add-an-index-to

Re: [R] Analyzing Publications from Pubmed via XML

2007-12-15 Thread David Winsemius
"Farrel Buchinsky" <[EMAIL PROTECTED]> wrote in news:[EMAIL PROTECTED]: > On Dec 13, 2007 11:35 PM, Robert Gentleman <[EMAIL PROTECTED]> wrote: >> or just try looking in the annotate package from Bioconductor >> > > Yip. annotate seems to be the most streamlined way to do this. > 1) How does one

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Adrian Dusa
On Saturday 15 December 2007, Prof Brian Ripley wrote: > On Sat, 15 Dec 2007, Adrian Dusa wrote: > > Indeed, I noticed the "host" argument but the server demands an username > > and a password for the machine first, > > But you said 'connect to', not 'log in to', so how were we to know that? > > >

[R] X11 uses font size 25 although 28 was requested

2007-12-15 Thread Andre Jung
Hi, I'm not sure if the real English warning is the same. I translated it from German. R came up with the following message: --- Warning message: In title(main = sinc.exp) : X11 nutzt Schriftgröße 25 obwohl 28 angefordert war [engl.: X11 uses fo

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Gabor Grothendieck
Use ssh forwarding to forward local port 3307 to remote port 3306 specifying the remote account and password. Then if you use local port 3306 you can access your local version of MySQL and if you use port 3307 you can access the remote version. There is some info on the MySQL site. First test i

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Prof Brian Ripley
On Sat, 15 Dec 2007, Adrian Dusa wrote: > > Indeed, I noticed the "host" argument but the server demands an username and a > password for the machine first, But you said 'connect to', not 'log in to', so how were we to know that? > and only after that for the MySQL server. > Those were the argum

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Adrian Dusa
Indeed, I noticed the "host" argument but the server demands an username and a password for the machine first, and only after that for the MySQL server. Those were the arguments I was looking for. I will study the RODBC package then, if it solves the problem. Thank you very much, Adrian On Sa

Re: [R] how to threshold a matrix

2007-12-15 Thread Gabor Grothendieck
Try: (M >= 0.3) - (M <= 0.3) On Dec 15, 2007 10:56 AM, affy snp <[EMAIL PROTECTED]> wrote: > Dear list, > > I have a matrix M (2500 rows and 9 columns). It looks like > > 2.2 0.1 2.63.6 .. > 0.4 1.9 2.74.2.. > 1.8 2.5 4.32.2... >

[R] how to threshold a matrix

2007-12-15 Thread affy snp
Dear list, I have a matrix M (2500 rows and 9 columns). It looks like 2.2 0.1 2.63.6 .. 0.4 1.9 2.74.2.. 1.8 2.5 4.32.2... . If I want to do: (1) if M[i,j]>=0.3, M[i,j]=1 (2) if M[i,j]<=-0.3, M[i,j]=-1 (3) Otherwise, M[i,j]=

Re: [R] garch function in tseries package

2007-12-15 Thread Prof Brian Ripley
On Sat, 15 Dec 2007, Prof Brian Ripley wrote: > This has been reported several times. I posted a workaround earlier this > week: > > https://stat.ethz.ch/pipermail/r-help/2007-December/148290.html The promised update, tseries_0.10-13.tar.gz, is on the CRAN master in source form. Expect a binar

[R] How to analyze observations list-wise deleted?

2007-12-15 Thread Chengshan Liu
I am using lrm in Design package for a project using logit analysis. I think lrm is very useful for providing information about the number of missing values due to the inclusion of each variable. My first questions is: How to explore those observations that are automatically deleted from the lrm?

Re: [R] modify a data.frame within a function

2007-12-15 Thread Mark Wardle
You need to read about scope. Try using return() from within your function to return the modified data frame to the caller. Best wishes, Mark On 15/12/2007, Yuval Sapir <[EMAIL PROTECTED]> wrote: > Hello all, > I'm trying to modify a single column of a data frame to remove randomly half > of

Re: [R] truncated fields with RODBC

2007-12-15 Thread Mikkel Grum
For the record, the problem with truncated fields below was solved by increasing the Max LongVarChar variable in the data source settings page 1 from 8190 to 32760. So it was a psqlODBC problem not an RODBC problem. The command nchar(Grids$Grids) helped me see how large the fields actually were

Re: [R] garch function in tseries package

2007-12-15 Thread Prof Brian Ripley
This has been reported several times. I posted a workaround earlier this week: https://stat.ethz.ch/pipermail/r-help/2007-December/148290.html so your searching of the archives was not very thorough! Another workaround is to use rterm instead of Rgui. On Sat, 15 Dec 2007, Kazuhiko SHINKI wro

Re: [R] VARMA in R

2007-12-15 Thread creepa1982
Hey Giovanni, thanks a lot for the help. I tried out combining the two functions dlmModARMA and dlmMLE and it works. The only problem I have right now is this. When I pass on the information about the starting parameters (param) in the dlmMLE function I can only input one parameter vector. Howev

[R] modify a data.frame within a function

2007-12-15 Thread Yuval Sapir
Hello all, I'm trying to modify a single column of a data frame to remove randomly half of the values. I want to do it within a function, but can not assign the modified column back into the data frame. It was easy and successful without a function, so I suspect the problem is the call of the s

Re: [R] calculating the number of days from dates

2007-12-15 Thread Martin Maechler
> "KK" == Knut Krueger <[EMAIL PROTECTED]> > on Sat, 15 Dec 2007 08:39:02 +0100 writes: KK> Bob Green schrieb: >> >> > dates <- read.csv("c:\\dates.csv",header=T) >> > dates >> v1 v2 >> 1 12/12/1978 12/12/2005 >> 2 23/01/1965 23/09/2001 >> 3 24/

Re: [R] Function built with segments

2007-12-15 Thread Martin Maechler
> "t" == thierrydb <[EMAIL PROTECTED]> > on Fri, 14 Dec 2007 07:19:56 -0800 (PST) writes: t> Hello, t> I'm new to R. If I have a set of 10 points (X(i), Y(i)), is there an elegant t> way to build a function y=f(x) that would be build out of the consecutive t> segmen

Re: [R] rcom close Excel problem

2007-12-15 Thread Gyula
First, you will likely have to use Ctrl-Alt-Delete - Task Manager - to kill the Excel processes. you could also try wb[["Saved"]]<-TRUE # trick Excel to think that the workbook is saved x$Quit() # close Excel rm(list=ls()) # remove all objects attached to environment Gyula On Dec 14, 11:58

[R] Truncated normal distribution

2007-12-15 Thread Ravi Longia
I am using TNORM - rtnorm to simulate from a truncated normal distribution. However, the current function available allows us to define the mean and SD of the non-truncated (original) distribution and then run the simulation. http://rss.acs.unt.edu/Rdoc/library/msm/html/tnorm.html I would instead

[R] Array dimnames

2007-12-15 Thread dave mitchell
Dear all, Possibly a rudimentary question, however any help is greatly appreciated. I am sorting a large matrix into an array of dim(p(i),q,3). I put each entry into a corresponding matrix (1 of the 3) based on some criteria. I figure this will assist me in condensing code as I can loop through

[R] Function built with segments

2007-12-15 Thread thierrydb
Hello, I'm new to R. If I have a set of 10 points (X(i), Y(i)), is there an elegant way to build a function y=f(x) that would be build out of the consecutive segments of X(j),Y(j) points (with X(j) sorted)? Thank you very much TDB -- View this message in context: http://www.nabble.com/Fun

[R] garch function in tseries package

2007-12-15 Thread Kazuhiko SHINKI
I am wondering how to run 'garch' function of 'tseries' package in R2.6.1. I installed R2.3.1 and R2.6.1 in my PC (Windows XP Home) and run a following simple GARCH function in both versions: >garch(dSP[1:300], order = c(1,1)) where 'dSP' is daily return series of a stock inde

Re: [R] connecting RMySQL to and external server

2007-12-15 Thread Prof Brian Ripley
It is trivial with RODBC (I know that is not what you asked, but it is the solution we found first). For RMySQL, note first that the MySQL configuration file is consulted, so the default host is specified in the client section, which is like [client] port=3306 [mysql] default-character-set=