[R] Break up a data frame

2008-03-20 Thread Ravi S. Shankar
Hi R users, I have a dataframe in the below format xyz 01/03/200715.25USD xyz 01/04/200715.32USD xyz 01/02/200823.22USD abc 01/03/2007

[R] create matrix

2008-03-20 Thread Felix Zajitschek - UNSW
Hi all, I have a dataset consisting of 5 columns and over 5000 rows. Each row gives information about an individual animal, including longevity, i.e. at what age an animal died. For the model I use I need to create n rows for each animal, n being its longevity, and a new column 'survival' with a

[R] How to cope with : /usr/bin/ld/: cannot find -lgfortran

2008-03-20 Thread Ndoye Souleymane
Good Morning, I am running R-2.6.1-1.rh5.i386.rpm under RED HAT Enterprise Linux 5, but I get this message error /usr/bin/ld/: cannot find -lgfortran when trying installing R CMD INSTALL ade4_1.4-5.tar.gz. Please help me to cope with this problem. Best regards, Souleymane

Re: [R] executable script

2008-03-20 Thread mysimbaa
Can you please give me some additional informations. I never created a .bat I have no experience. Peter Alspach wrote: Kia ora unknown requestor One option is to create a .bat file along the following lines: path_to_R\bin\R CMD BATCH yourScript.R Peter Alspach -Original

Re: [R] basic help

2008-03-20 Thread Chuck Cleland
On 3/20/2008 12:59 AM, מוטי אסולין wrote: Hi, I am a new R user (used SPSS for many years) and I need help. I have a data frame mydata with 8 variables m2008:m2001 I wanted to add a new variable mydata$firstvalid that tells me what is the first non missing variable for each case (without

Re: [R] How to cope with : /usr/bin/ld/: cannot find -lgfortran

2008-03-20 Thread Prof Brian Ripley
Good Morning, Please don't post twice! Please don't post twice! (The two R-help addresses you used are the same list.) Did I mention that posting twice is counter-productive? On Thu, 20 Mar 2008, Ndoye Souleymane wrote: Good Morning, I am running R-2.6.1-1.rh5.i386.rpm under RED HAT

Re: [R] How to plot the dendrogram or tree for kmeans ?

2008-03-20 Thread hadley wickham
On Thu, Mar 20, 2008 at 5:45 AM, [EMAIL PROTECTED] wrote: Why do you think there is one? kmeans is an agglomerative clustering algorithm, not a recursively dividing one. Since there is no clustering hierarchy, so there is no dendrogram. However, you could create a clustergram:

Re: [R] Break up a data frame

2008-03-20 Thread jim holtman
Is this close to what you want? x - read.table('clipboard') x V1 V2V3 V4 1 xyz 01/03/2007 15.25 USD 2 xyz 01/04/2007 15.32 USD 3 xyz 01/02/2008 23.22 USD 4 abc 01/03/2007 45.20 EUR 5 abc 01/04/2007 45.00 EUR 6 abc 01/02/2008 68.33 EUR x.m - melt(x) Using V1, V2, V4 as id

Re: [R] create matrix

2008-03-20 Thread jim holtman
Since you did not provide a sample of your data, here is an example of how to take a vector and create a matrix with 5 entries for each value, with the extra ones having a zero in the second column: x - sample(1:7, 20, T) table(x) x 1 2 3 4 5 6 7 2 4 3 2 4 4 1 # create a matrix with 5 rows of

[R] how can I reorder a dendrogram?

2008-03-20 Thread Thomas Walter
Hi! I am trying to reorder a dendrogram via reorder.dendrogram. However, I observed some problems with this, and I will illustrate them with an example. Take the following clustering problem: datamatrix - matrix(c(2,2,2.5,2,1.5,2,2,1.5,2,2.5, 6,2,6.5,2,5.5,2,6,1.5,6,2.5,

[R] gui to run script

2008-03-20 Thread mysimbaa
Dear R users, I'm trying since longtime to make an autolaunch of my code, but no results. I have programmed three codes. And depending on my data(logfile collected from another source) I have (frequently) to run one of the three codes. I'm looking for a better solution that run on of the codes

Re: [R] how can I reorder a dendrogram?

2008-03-20 Thread Thomas Walter
Oups ... sorry, actually I found the problem. The problem lies not with the reordering but with the construction of the dendrogram: if a hierarchical method is used, there are never more than 2 branches for a node. Therefore, the reordering does not give the expected result. I will have to try

Re: [R] Cointegration no constant

2008-03-20 Thread Pfaff, Bernhard Dr.
Hi, I am trying to estimate a VECM without constant using the following code: data(finland) sjf - finland sjf.reg-ca.jo(sjf, type = c(eigen), ecdet = c(none), K = 2,spec=c(transitory), season = NULL, dumvar = NULL) cajools(sjf.reg) While the cointegration test does not use a constant, it is

[R] Problem with diff(strptime(...

2008-03-20 Thread Jim Lemon
Hi all, I have been chipping away at a problem I encountered in calculating rates per year from a moderately large data file (46412 rows). When I ran the following command, I got obviously wrong output: interval- c(NA,as.numeric(diff( strptime(mkdf$MEAS_DATE,%d/%m/%Y)))/365.25) The values

[R] interperting a regression tree

2008-03-20 Thread Sharma, Manju
hello i am trying to decipher a dendrogram i have from performing a 'tree'. (attached file) my response variable is factored - low, medium and high threat and the 8 explanatory variables are numeric values. i could do with some help to understand what the values 0.25, 0.5 and 0.75 are on

Re: [R] Break up a data frame

2008-03-20 Thread Henrique Dallazuanna
Or perhaps: xtabs(V3 ~ V2 + V4, data=x) On 20/03/2008, Ravi S. Shankar [EMAIL PROTECTED] wrote: Hi R users, I have a dataframe in the below format xyz 01/03/200715.25USD xyz 01/04/200715.32USD

[R] conditional matching of rows of tables

2008-03-20 Thread Ng Stanley
Hi, Given matrix A of 4 cols. 1 a 0 4 1 b 5 8 2 a 0 3 2 b 4 7 I have another matrix B of 3 cols. How to assign (a or b) to the rows such that in each row its 1st value must match the 1st col. of A, 2nd and 3rd values must lie between 3rd and 4rd cols (inclusive) of A 1 2 3 - a 2 4 5 - b 2 0 3

Re: [R] Equal vertical spaced labels on plot with log=y

2008-03-20 Thread Jim Lemon
Daniel Brewer wrote: Hello, I have a series of labels that I want to place on a plot with a log scale y axis. I want these labels to be equally spaced vertically as seen on the plot. I have been trying this: ylab - 160 - log2(1:length(labels)) but that does not seem to work (where

Re: [R] Problem with diff(strptime(...

2008-03-20 Thread Prof Brian Ripley
You are throwing away the clue in your use of as.numeric. First. strptime returns a POSIXlt value, which you will convert to POSIXct when you do arithetic (using diff()). Why are you doing that? So foodate-factor(c(1/7/1991,1/8/1991,1/8/1991,3/8/1991)) diff(strptime(foodate,%d/%m/%Y)) Time

[R] Multiple plots question

2008-03-20 Thread Andre Nathan
Hello (Sorry if this appears twice, had some mail problems...) I have a number of different data sets, each loaded as a matrix. I'd like to plot them in a way that the data in the first column of each matrix is plotted on the same pair of axes. What I'm doing now is to call plot() for the data

Re: [R] how can I reorder a dendrogram?

2008-03-20 Thread Philippe Grosjean
Hello, Perhaps, you should chose another toy example closer to the reality. Cases with exactly same distance rarely occur in the field. You should, at least, add some random error: datamatrix - matrix(c(2,2,2.5,2,1.5,2,2,1.5,2,2.5, 6,2,6.5,2,5.5,2,6,1.5,6,2.5, 4,4,4.5,4,3.5,4,4,3.5,4,4.5) +

Re: [R] create matrix

2008-03-20 Thread Simon Blomberg
There may be a less baroque way of doing it, but does this do what you want? Say you have a data.frame called dat: dat x1 x2 Longevity 1 -1.9582519 a 4 2 0.8724081 b 2 3 -0.9150847 c 5 # now create a new long data.frame: dat.long -

Re: [R] analyzing binomial data with spatially correlated errors

2008-03-20 Thread Roger Bivand
Ben Bolker bolker at ufl.edu writes: Jean-Baptiste Ferdy Jean-Baptiste.Ferdy at univ-montp2.fr writes: Dear R users, I want to explain binomial data by a serie of fixed effects. My problem is that my binomial data are spatially correlated. Naively, I thought I could found

Re: [R] Problem with diff(strptime(...

2008-03-20 Thread Jim Lemon
Prof Brian Ripley wrote: You are throwing away the clue in your use of as.numeric. First. strptime returns a POSIXlt value, which you will convert to POSIXct when you do arithetic (using diff()). Why are you doing that? So foodate-factor(c(1/7/1991,1/8/1991,1/8/1991,3/8/1991))

[R] Rmpi and C Code, where to get the communicator

2008-03-20 Thread Markus Schmidberger
Hello, I try to write parts of my code in C to accelerate the for-loops. But basic operations I want to do in R (e.g. start cluster). My R code looks something like this: library(Rmpi) mpi.spawn.Rslaves() mpi.remote.exec() dyn.load(test.so) erg - .Call(test, ) mpi.close.Rslaves()

Re: [R] analyzing binomial data with spatially correlated errors

2008-03-20 Thread Rubén Roa-Ureta
Roger Bivand wrote: Ben Bolker bolker at ufl.edu writes: Jean-Baptiste Ferdy Jean-Baptiste.Ferdy at univ-montp2.fr writes: Dear R users, I want to explain binomial data by a serie of fixed effects. My problem is that my binomial data are spatially correlated. Naively, I thought I

Re: [R] analyzing binomial data with spatially correlated errors

2008-03-20 Thread Douglas Bates
On Wed, Mar 19, 2008 at 3:02 PM, Ben Bolker [EMAIL PROTECTED] wrote: Jean-Baptiste Ferdy Jean-Baptiste.Ferdy at univ-montp2.fr writes: Dear R users, I want to explain binomial data by a serie of fixed effects. My problem is that my binomial data are spatially correlated. Naively,

Re: [R] Smoothing z-values according to their x, y positions

2008-03-20 Thread David Winsemius
Emmanuel Levy [EMAIL PROTECTED] wrote in news:[EMAIL PROTECTED]: Dear David, Thanks a lot for pointing out kde2d, just tried it out but the problem is that it indeed takes the density of points into account, which I dont want. For example, if in an region of surface S I've got 10,000

[R] coxme - bug / error

2008-03-20 Thread Rasanga Ruwanthi
Hello everyone, Many thanks to Terry Therneau for giving me a solution for my previous problem re coxme function. Now, I am using a bigger dataset to fit the same model; random treatment effect nested within centre. I used the command coxme(Surv(time, status) ~ factor(treat), data=data1,

[R] comparing length-weight regressions]

2008-03-20 Thread Rubén Roa-Ureta
[EMAIL PROTECTED] wrote: I'd like to compare length-weight regressions among years. Any information would be appreciated. a. gray fisheries consultant Your message is rather cryptic for a general statistical audience, whereas I'm sure in a fisheries group everybody would understand what

[R] ggplot - axis labels angle

2008-03-20 Thread Bernd Ebersberger
dear R-tists, im an struggling with labeling ticks of the axis in a ggplot. i would like to print the text associated with the ticks being ploted with a 90 degree angle. how can i possibly do this? cheers. bernd. ~ Bernd Ebersberger Management Center

Re: [R] Break up a data frame

2008-03-20 Thread David Winsemius
Ravi S. Shankar [EMAIL PROTECTED] wrote in news:[EMAIL PROTECTED]: Hi R users, I have a dataframe in the below format xyz 01/03/200715.25USD xyz 01/04/200715.32USD xyz

[R] Rmpi and C Code, where to get the communicator

2008-03-20 Thread Markus Schmidberger
Hello, I try to write parts of my code in C to accelerate the for-loops. But basic operations I want to do in R (e.g. start cluster). My R code looks something like this: library(Rmpi) mpi.spawn.Rslaves() mpi.remote.exec() dyn.load(test.so) erg - .Call(test, ) mpi.close.Rslaves()

Re: [R] analyzing binomial data with spatially correlated errors

2008-03-20 Thread Ben Bolker
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Douglas Bates wrote: | On Wed, Mar 19, 2008 at 3:02 PM, Ben Bolker [EMAIL PROTECTED] wrote: | Jean-Baptiste Ferdy Jean-Baptiste.Ferdy at univ-montp2.fr writes: | | | Dear R users, | | I want to explain binomial data by a serie of fixed

[R] Use of Factors

2008-03-20 Thread Beck, Kenneth (STP)
Relatively new to R, I'm trying to do a relatively simple task. I have data set that has several variables arranged by SubjID and visit, with multiple observations for that combination. I do linear regression on those multiple observations, then generated a set of interpolated values from the

[R] little subplot in corner

2008-03-20 Thread Thomas Steiner
I want to draw a little subplot (overview) into my detailed plot. It should be placed in say the top right corner and have the size of some legend (like legend(x=topright, inset=0.03, ...) #main plot plot(rnorm(100)) #give little density in corner

[R] Installation of R, Sweave, ESS and [X]Emacs on Windows?

2008-03-20 Thread Zembower, Kevin
I'm trying to get R, Sweave, ESS and XEmacs or emacs all installed and working together on my Windows XP Pro system. I've got R 2.6.0 working just fine, installed from the R Windows installer. I also have CYGWIN_NT-5.1 with XEmacs 21.4 working okay. Can anyone point me to any documentation on how

[R] Fwd: time series regression

2008-03-20 Thread bereket weldeslassie
Hi Everyone, I am trying to do a time series regression using the lm function. However, according to the durbin watson test the errors are autocorrelated. And then I tried to use the gls function to accomodate for the autocorrelated errors. My question is how do I know what ARMA process (order) to

[R] Fwd: time series regression

2008-03-20 Thread bereket weldeslassie
Hi Everyone, One more information to my question. I am trying to do a time series regression using the lm function. *My intention is to investigate the relationship between a dependent time series variable and several independent time series variables.* According to the durbin watson test the

Re: [R] Installation of R, Sweave, ESS and [X]Emacs on Windows?

2008-03-20 Thread James W. MacDonald
Hi Kevin, Go here: http://vgoulet.act.ulaval.ca/en/ressources/emacs/ and get Vincent Goulet's Emacs for Windows. Not sure how cygwin enters into the picture; you don't need it for either R, [X]Emacs, nor ESS. In fact, if you ever plan to build packages on Windows having cygwin installed can

Re: [R] Installation of R, Sweave, ESS and [X]Emacs on Windows?

2008-03-20 Thread Vincent Goulet
Kevin, Save yourself a lot of trouble and use my modified version of GNU Emacs available from http://vgoulet.act.ulaval.ca/en/emacs and also linked from the ESS home page. It comes bundled with ESS and AUCTeX, so the only other thing you will need to install for the purposes you

Re: [R] Rmpi and C Code, where to get the communicator

2008-03-20 Thread Martin Morgan
Hi Markus -- Usually comm is an argument with default value in the mpi.* functions, so implicitly the user is managing these, e.g., by default, using comm 1. Presumably you'll have an R wrapper to .Call that has a default argument comm=1, and will passs this to the C level. Martin Markus

Re: [R] Installation of R, Sweave, ESS and [X]Emacs on Windows?

2008-03-20 Thread Zembower, Kevin
Jim and Vincent, thank you both so much. Vincent, I really appreciate the time and effort you've put into this project. I was hoping for exactly what you've provide. Thanks, again. -Kevin -Original Message- From: Vincent Goulet [mailto:[EMAIL PROTECTED] Sent: Thursday, March 20, 2008

Re: [R] Fwd: time series regression

2008-03-20 Thread Mark Leeds
Your entering into a complex danger zone here because you really need to check first if all the dependent and independent variables are stationary. Otherwise, your lm results are meaningless ( you're estimation a spurious regression ). I would look at Bernhard Pfaff's yellow book or any other

Re: [R] Fwd: time series regression

2008-03-20 Thread Thibaut Jombart
bereket weldeslassie wrote: Hi Everyone, One more information to my question. I am trying to do a time series regression using the lm function. *My intention is to investigate the relationship between a dependent time series variable and several independent time series variables.* According

Re: [R] conditional matching of rows of tables

2008-03-20 Thread jim holtman
Not exactly clear on the transformation that you want to do. In your example, '1 2 3 - a', where does the '2 3' come from since I don't see a value of 2 in the 3rd 4th columns. So a better explanation of what you are trying to do would be help and show where the values came from in each case.

Re: [R] Fwd: time series regression

2008-03-20 Thread Hannu Kahra
Use the arima function with the xreg option that is a vector or matrix of external regressors. Use AIC or BIC when identifying the error process. Hannu On Thu, Mar 20, 2008 at 5:54 PM, bereket weldeslassie [EMAIL PROTECTED] wrote: Hi Everyone, One more information to my question. I am trying

[R] I need help integrating ggplot2 into Excel

2008-03-20 Thread Jannik Vindeloev
Dear all I use ggplot2 extensively for my plotting routines and rexcel to have the best of two worlds. (RExcel v 1.75 and R (D)Com v. 2.5) I can run my ggplot functions, such as qplot(...), in scratchpad mode, but not in Macro nor Worksheet functions mode. I have tried the following in Macro

[R] time series regression

2008-03-20 Thread bereket weldeslassie
Hi Everyone, I am trying to do a time series regression using the lm function. However, according to the durbin watson test the errors are autocorrelated. And then I tried to use the gls function to accomodate for the autocorrelated errors. My question is how do I know what ARMA process (order) to

[R] minimum distances

2008-03-20 Thread Dave Depew
Hi, I have a question about computing shortest Euclidean distances between two data frames of spatial points... I have 2 dataframes (not yet converted to spatial class) Sewers-data.frame(x=c(10,20,35,50),y=c(100,150,200,300)) transect - data.frame(x=seq(from=0, to=50, by=1),y=seq(from=100,

Re: [R] little subplot in corner

2008-03-20 Thread Henrique Dallazuanna
I don't if is this what you want, but: plot(rnorm(100)) par(fig=c(0, 1/2, 0, 1/2), new=T) plot(seq(-2,2,length=300),dnorm(seq(-2,2,length=300)),type=l, axes = F, xlab=, ylab=) On 20/03/2008, Thomas Steiner [EMAIL PROTECTED] wrote: I want to draw a little subplot (overview) into my detailed

Re: [R] little subplot in corner

2008-03-20 Thread Thomas Steiner
perfect, exactly what I was looking for. Thanks a lot! many eggs to you... Thomas __ 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

[R] logLik calculations

2008-03-20 Thread kyoung
Does the “logLik” function applied to a “glm” and “glm.nb” (from MASS package) calculate the complete log-likelihoods, or does it drop the constant terms of the equation? (It’s not clear from the associated help pages, and I’ve found no reference from searching the R help mailing list) Thank

Re: [R] minimum distances

2008-03-20 Thread Ben Bolker
Dave Depew ddepew at sciborg.uwaterloo.ca writes: Hi, I have a question about computing shortest Euclidean distances between two data frames of spatial points... I have 2 dataframes (not yet converted to spatial class) Sewers-data.frame(x=c(10,20,35,50),y=c(100,150,200,300))

Re: [R] I need help integrating ggplot2 into Excel

2008-03-20 Thread Greg Snow
I expect that this is the same as FAQ 7.22, though the FAQ should probably be updated to include ggplot as well as lattice/trellis. Basically you need to print the graph (in some modes it is automatically printed, so you see it, in other modes it is not autoprinted, so you see nothing), just

Re: [R] little subplot in corner

2008-03-20 Thread Greg Snow
Look at the subplot function in the TeachingDemos package (the cnvrt.coords function in the same package can be used to help in finding coordinates to place the plot). Hope this helps, -- Gregory (Greg) L. Snow Ph.D. Statistical Data Center Intermountain Healthcare [EMAIL PROTECTED] (801)

[R] Interpretation of Variance decomposition in VAR model

2008-03-20 Thread Ron Michael
Hi all, This question is not really R related, rather on Statistics subject itself. Even I did not do those using R. however still I want to post it here, because my hope is I could get help from great statisticians who are the very active member of this group. My problem is to interpret

[R] Interpretation of Variance decomposition in VAR model

2008-03-20 Thread Ron Michael
Hi all, This question is not really R related, rather on Statistics subject itself. Even I did not do those using R. however still I want to post it here, because my hope is I could get help from great statisticians who are the very active member of this group. My problem is to interpret

Re: [R] basic help

2008-03-20 Thread מוטי אסולין
Thank you, it worked perfectly. Moti -Original Message- From: Chuck Cleland [mailto:[EMAIL PROTECTED] Sent: Thursday, March 20, 2008 10:40 AM To: מוטי אסולין Cc: r-help@r-project.org Subject: Re: [R] basic help On 3/20/2008 12:59 AM, מוטי אסולין wrote: Hi, I am a new R user (used SPSS

[R] analysis on Pcap dataset

2008-03-20 Thread Neo23
Hi, I want to do some analysis on pcap datasets.. so is there any package which take cares of that.. If someone has already worked on this, could you give me some tips... thanks, Neo23 -- View this message in context: http://www.nabble.com/analysis-on-Pcap-dataset-tp16187570p16187570.html

[R] download webpage in R

2008-03-20 Thread gilbert feng
Hi, everyone I want to download a XML webpage and save it as a file in my local machine. Is there any way to do it in R? Thanks a lot Gilbert [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

Re: [R] download webpage in R

2008-03-20 Thread Gabor Csardi
If you do help.search(download) you find ?download.file G. On Thu, Mar 20, 2008 at 04:51:22PM -0500, gilbert feng wrote: Hi, everyone I want to download a XML webpage and save it as a file in my local machine. Is there any way to do it in R? Thanks a lot Gilbert

Re: [R] download webpage in R

2008-03-20 Thread Martin Morgan
Also the XML package for processing the file once retrieved. Martin Gabor Csardi wrote: If you do help.search(download) you find ?download.file G. On Thu, Mar 20, 2008 at 04:51:22PM -0500, gilbert feng wrote: Hi, everyone I want to download a XML webpage and save it as a file

[R] Importing an Excel spreadsheet

2008-03-20 Thread andy
Hello I am trying to import an *.xls spreadsheet into R. I am doing this as follows: read.table(file(A5_DL.xls)) But obtain the error: Error in type.convert(data[[i]], as.is = as.is[i], dec = dec, na.strings = character(0)) : invalid multibyte string at '?' So I copied it all over to

Re: [R] download webpage in R

2008-03-20 Thread Duncan Temple Lang
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 And if the Web page requires anything more than basic access, e.g. if it uses a password or SSL (via https), you can use RCurl to make more advanced, customizable HTTP/FTP requests. ~ D. Gabor Csardi wrote: | If you do | | help.search(download) |

Re: [R] Importing an Excel spreadsheet

2008-03-20 Thread ken knoblauch
andy geek_show at dsl.pipex.com writes: I am trying to import an *.xls spreadsheet into R. I am doing this as follows: read.table(file(A5_DL.xls)) So I copied it all over to a text document and tried to import that, thus: read.table(A5.txt) The error I got then was: Error in scan(file,

Re: [R] Importing an Excel spreadsheet

2008-03-20 Thread Bryan K Woods
If you open the spreadsheet in Excel you can then do Save as... and select type CSV (comma-delimited text). Once you have the data in CSV format, you can use the R function read.csv to import the data. Cheers, Bryan andy wrote: Hello I am trying to import an *.xls spreadsheet into R. I am

Re: [R] Importing an Excel spreadsheet

2008-03-20 Thread andy
Bryan K Woods wrote: If you open the spreadsheet in Excel you can then do Save as... and select type CSV (comma-delimited text). Once you have the data in CSV format, you can use the R function read.csv to import the data. Cheers, Bryan andy wrote: Hello I am trying to import an *.xls

[R] setMethod for [

2008-03-20 Thread Musa Parmaksiz
Hi R-Help, Please consider the following simple case: I have a class like setClass(myClass, representation(x=matrix, y=character)) and I would like to use the method *[* for a *myClass* objects (but changing the default *drop* argument from TRUE to FALSE): setMethod([,myClass,

[R] Error in function (classes, fdef, mtable): unable to find an inherited method for function indexProbes, for signature exprSet, character

2008-03-20 Thread Suprabhath
Hello Everyone, I am writing programs in R from 7 months and I am able to solve most of the errors/issues except for this current post. My Task is to read a Microsoft Excel file(textE_to_affy.csv) which contains the Microarray Expression Values collected from the Illumina Microarray

Re: [R] setMethod for [

2008-03-20 Thread Martin Morgan
Hi Musa -- Musa Parmaksiz wrote: Hi R-Help, Please consider the following simple case: I have a class like setClass(myClass, representation(x=matrix, y=character)) and I would like to use the method *[* for a *myClass* objects (but changing the default *drop* argument

Re: [R] Error in function (classes, fdef, mtable): unable to find an inherited method for function indexProbes, for signature exprSet, character

2008-03-20 Thread Martin Morgan
This is a Bioconductor package, ask on the Bioc mailing list http://bioconductor.org More comments below... Suprabhath wrote: Hello Everyone, I am writing programs in R from 7 months and I am able to solve most of the errors/issues except for this current post. My Task is to read a

Re: [R] conditional matching of rows of tables

2008-03-20 Thread Stanley Ng
Second try :P I have matrix A of 4 cols: 1 a 0 4 1 b 5 8 2 a 0 3 2 b 4 7 And matrix B of 3 cols: 1 2 3 2 4 5 2 0 3 1 7 8 I would like to assign (a or b) to the rows of matrix B. The rules are that in each row of matrix B, the 1st value must match the 1st col. of matrix A, 2nd and 3rd

Re: [R] setMethod for [

2008-03-20 Thread Musa Parmaksiz
Hi Martin, Thanks for the suggestions. If possible I would avoid defining several methods with different signatures. For the first solution,namely setMethod([, signature=signature(x=myClass), function(x, i, j, ..., drop=FALSE) { if (missing(i) missing(j))

[R] coredump at the of 'configure' and error for 'make'

2008-03-20 Thread tomkur2006-takehome
Hi, I got some errors when I attempted to build R on my Solaris 9 box. Can someone please provide some suggestion on what to do next? The configure process was fine expect that I got a some warning message and a coredump at the end. What does that affect? Can I still build it? ./configure

Re: [R] conditional matching of rows of tables

2008-03-20 Thread jim holtman
This should do it for you: A V1 V2 V3 V4 1 1 a 0 4 2 1 b 5 8 3 2 a 0 3 4 2 b 4 7 B V1 V2 V3 1 1 2 3 2 2 4 5 3 2 0 3 4 1 7 8 B1 - B # create a copy and add a new column B1$key - for (i in seq(nrow(B))){ + indx - which((B[i,1] == A[,1]) (B[i,2] = A[,3])

Re: [R] Use of Factors

2008-03-20 Thread jim holtman
Do 'str' on your object and you will see that they are 'factors'. May have gotten that way when you read them in and there was character data in the column. To convert it back to numeric, do: cpx_interp$HR - as.numeric(as.character(cpx_interp$HR)) On Thu, Mar 20, 2008 at 9:26 AM, Beck,

[R] hist - modify maximum frequency (vertical axis)

2008-03-20 Thread Omar Baqueiro
Hello, Is there a way to easily specify the maximum value to draw a histogram with the hist function? I have 6 histograms, but each of them is drawn with a different frequency range (scaling them to the best visible way), however I need all the histograms to be scaled so that the maximum

Re: [R] I need help integrating ggplot2 into Excel

2008-03-20 Thread Felipe Carrillo
Create an R script,name it Myggplot2 and place it on your desktop.In excel open the vb editor and write this code: Sub Myggplot2() 'start R Call rinterface.StartRServer 'Put the dataframe into R,assuming that your 'data is in sheet1 cells A1:D1 Call rinterface.PutDataframe(yourdataframename,

Re: [R] hist - modify maximum frequency (vertical axis)

2008-03-20 Thread Daniel Malter
Hi, type ?hist in the R prompt and look for the ylim argument. Example: x=rep(1:10,1:10) hist(x,ylim=c(0,20)) Manipulate the ylim values as needed. Cheers, Daniel - cuncta stricte discussurus - -Ursprüngliche Nachricht- Von: [EMAIL

Re: [R] interperting a regression tree

2008-03-20 Thread Bill.Venables
If you have fitted a tree model, the diagram (which did not survive the mailing list, of course) would have been a decision tree, not a dendrogram. In a decision tree, the internal nodes refer to decisions to be made as to whether to proceed to the left or to the right at that stage. This is

Re: [R] logLik calculations

2008-03-20 Thread Bill.Venables
library(MASS) methods(logLik) [1] logLik.Arima*logLik.fitdistr* logLik.gam logLik.glm* [5] logLik.glmmPQL* logLik.lm* logLik.negbin* logLik.nls* [9] logLik.polr* Non-visible functions are asterisked glmgenerates an object of class glm, so tick! glm.nb