Re: [R] DOE in R?

2009-09-06 Thread Carlos J. Gil Bellosta
Hello, This is your starting point: http://cran.r-project.org/web/views/ExperimentalDesign.html Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Thu, 2009-09-03 at 17:38 -0700, B_miner wrote: > Hello! > > > This is not a topic I am well versed in but requir

Re: [R] DOE in R?

2009-09-08 Thread Carlos J. Gil Bellosta
However, you can check SAS's and R's D values to see to which extent the designs are far away from the "optimal". Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Sun, 2009-09-06 at 20:33 -0400, b miner wrote: > I attempted to use the package algdesign.

Re: [R] DOE in R?

2009-09-09 Thread Carlos J. Gil Bellosta
erministic nature of the search for optimality (and local optima) may lead to discrepancies between the outputs. You will have to work through the different proc/function inputs to make sure you are running an analogous algorithm on both systems. Best regards, Carlos J. Gil Bel

Re: [R] R Memory Usage Concerns

2009-09-15 Thread Carlos J. Gil Bellosta
ot;intermediate memory" to read the files. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-09-15 at 00:10 -0700, Evan Klitzke wrote: > On Mon, Sep 14, 2009 at 10:01 PM, Henrik Bengtsson > wrote: > > As already suggested, you're (much) better of

Re: [R] Large Stata file Import in R

2009-06-29 Thread Carlos J. Gil Bellosta
via install.packages("colbycol",repos="http://R-Forge.R-project.org";) Comments and bug reports are more than welcome! Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Mon, 2009-06-29 at 15:50 +0100, saurav pathak wrote: > Hi > > I am using St

Re: [R] Aggregate, max and time of max

2009-07-24 Thread Carlos J. Gil Bellosta
Hello, I believe that by( data.ex, data.ex[,c(3,4)], function(x) x[which.max(x[,1]),] ) does what you want. Then, do.call( rbind, by( data.ex, data.ex[,c(3,4)], function(x) x[which.max(x[,1]),] ) ) looks somewhat nicer. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On

Re: [R] Question about rpart decision trees (being used to predict customer churn)

2009-08-01 Thread Carlos J. Gil Bellosta
t a complexity parameter below that value, this is, never. You may need to go into the internals of the function (and the C code) in order to understand how this parameter is calculated. It looks to me as an oddity and it is worth trying to understand why. Best regards, Carlos J. Gil Bellosta h

Re: [R] Question about rpart decision trees (being used to predict customer churn)

2009-08-02 Thread Carlos J. Gil Bellosta
rep("yes",5))) foo <- function( i ){ tmp <- rpart(cancel ~ experience, parms=list(loss=matrix(c(0,i,1,0), byrow=TRUE,nrow=2))) nrow( tmp$frame ) } sapply( 1:20, foo ) The ouput I get is: [1] 1 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 1 1 1 1 So, something unexpected happens after penaliz

Re: [R] how to avoid a script from hanging up

2009-08-02 Thread Carlos J. Gil Bellosta
it, etc. You can even consider saving your data into a database if need be. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Sun, 2009-08-02 at 20:02 +0200, mau...@alice.it wrote: > I am submitting this problem to the R forum , rather than the Bioconductor > forum, b

[R] Something similar to loess for 2D curves?

2010-04-30 Thread Carlos J. Gil Bellosta
detect possible outliers and interpolate in those points. I used two independent loess smoothers on the individual coordinates, but the results were not satisfactory as the correlation between both coordinates was ignored. Any ideas? Best regards, Carlos J. Gil Bellosta http://www.datanalyti

Re: [R] Ayuda exportar a SPSS

2010-04-30 Thread Carlos J. Gil Bellosta
Hola, ¿qué tal? Si quieres preguntar en español, puedes hacerlo a través de r-help-es: https://stat.ethz.ch/mailman/listinfo/r-help-es Un saludo, Carlos J. Gil Bellosta http://www.datanalytics.com P.D.: Es difícil que te podamos ayudar si no nos ofreces más detalles... On 04/30/2010 04:37

[R] R as a web service

2009-09-26 Thread Carlos J. Gil Bellosta
documentation available? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide

Re: [R] Memory Problems with CSV and Survey Objects

2009-10-24 Thread Carlos J. Gil Bellosta
ed in. It is just the same strategy Thomas suggested, only that without the requirement of an external tool and using almost the same syntax as you would use in case you had no memory problems. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Fri, 2009-10-23 at 09:36 -0400, An

Re: [R] Do you keep an archive of "useful" R code? and if so - how?

2009-11-22 Thread Carlos J. Gil Bellosta
your code and you would have an integrated search engine. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com Tal Galili wrote: Hello all, When using R for some time, one comes across more and more useful functions. But naturally we can't remember all of them, so I imag

Re: [R] help with repeated values

2009-12-06 Thread Carlos J. Gil Bellosta
Here you have an example: > colleges <- factor( c("a", "a", "b", "c", "c" )) > colleges [1] a a b c c Levels: a b c > table( colleges ) colleges a b c 2 1 2 > colleges.count <- table( colleges )[colleges] > colleges.count colleges a a b c c 2 2 1 2 2 > which( colleges.count > 1 ) a a c c 1 2 4 5

[R] "Overloading" some non-dispatched S3 methods for new classes

2009-05-09 Thread Carlos J. Gil Bellosta
e only alternative I can think about is to create decorated versions of ncol, nrow, etc. to avoid naming conflicts. But I would still prefer my package users to be able to use the undecorated function names. Do I have a chance? Best regards, Carlos J. Gil Bellosta http://

[R] Segmentation fault in package rJava on CentOS server

2009-05-13 Thread Carlos J. Gil Bellosta
ion fault at the .jinit call. In particular, when .jinit calls RinitJVM. Any ideas? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the p

[R] Bug in truncgof package?

2009-05-31 Thread Carlos J. Gil Bellosta
t the maintainer does not seem to be contactable, what would be the next step to take? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read th

[R] Recursive partitioning algorithms in R vs. alia

2009-06-19 Thread Carlos J. Gil Bellosta
- reason to pay hefty software licences? How would the algorithms implemented in rpart compare to those in SAS and/or CART? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/

Re: [R] I have a question about a programa in R

2009-03-22 Thread Carlos J. Gil Bellosta
Hello, And what is exactly your problem? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org

Re: [R] How to: Read Multi-filtes and sort to different files

2009-03-25 Thread Carlos J. Gil Bellosta
do.call( cbind, sapply( dir(), read.table, skip = 1, header = TRUE ) ) I have not been able to test the expression above and it may not even parse in R but it is close to something that should work. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2009-03-25 at 14:30 -0700

Re: [R] R on amazon's EC2 "cloud"?

2009-12-27 Thread Carlos J. Gil Bellosta
Hello, I tried Amazon EC2 with R recently and wrote an entry about it to a blog I collaborate with: http://analisisydecision.es/probando-r-sobre-el-ec2-de-amazon/ (Unfortunately, it is in Spanish...) Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com Blair Christian wrote

Re: [R] Is there a quicker way to drop a data frame column than setting it to NULL?

2010-01-24 Thread Carlos J. Gil Bellosta
Hello, You can always use df <- subset( df, select = -c(x, y, z) ) Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com Dimitri Shvorob wrote: If I want to drop columns x, y, z from dataframe df, is there a better alternative to df$x = NULL df$y = NULL df$z = NULL There

Re: [R] Feature selection

2010-01-24 Thread Carlos J. Gil Bellosta
You can check http://cran.r-project.org/web/views/MachineLearning.html Carlos J. Gil Bellosta http://www.datanalytics.com Amy Hessen wrote: Hi, Could you please tell me whether there are feature selection algorithms in R or not such as genetic algorithms? If so, could you please tell me

Re: [R] Read files in a folder when new data files come

2010-01-24 Thread Carlos J. Gil Bellosta
perhaps ask your users to use some kind of web interface to upload the data. This interface could then trigger an R process. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com jlfmssm wrote: Hello, I am working on a project. The new data files is coming as the data collectors

Re: [R] Applying a function on each columns of a matrix

2010-01-29 Thread Carlos J. Gil Bellosta
Hello, You could do something along the following lines: sapply( 1:ncol( my.matrix ), function( i ) my.foo( my.matrix[,i], my.parm[i] ) Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com anna wrote: Hello everyone, I have the following matrix

Re: [R] how to express time series linear model Q(t) ~ Q(t-1)+.. Q(t-n) as a formula

2010-01-29 Thread Carlos J. Gil Bellosta
Hello, You may problably need to create the lagged vars yourself and use them as input for the NN. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com http://datanalytics.wordpress.com CJ Rubio wrote: For example I have a time series Q(t) ~ Q(t-1) + Q(t-2) + Q(t-3) meaning

[R] Doubt about cluster analysis... y más

2010-02-02 Thread Carlos J. Gil Bellosta
primeras jornadas de usuarios de R, etc. Un cordial saludo, Carlos J. Gil Bellosta http://www.datanalytics.com Francisco Javier Santos Alamillos wrote: Dear R community, I'm a beginner with Cluster Analysis. I would like to know if there is a criterion to select the best set of clusters

Re: [R] Delete missing value rows from a matrix

2010-02-03 Thread Carlos J. Gil Bellosta
Hello, You can run a row-wise all( is.na( ) ). You will then detect rows consisting of NAs only. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com anna wrote: Hi everyone, I have a matrix with many Na's. Some rows contain some Na's and some others are entirely c

Re: [R] stupid R tricks

2010-11-21 Thread Carlos J. Gil Bellosta
nv), function(x) class(get(x)) ), function(y) cls %in% y) ] Hello, A simpler, less verbose version: getclass <- function(cls="data.frame") Filter( function( b ) any( cls %in% class( get( b ) ) ), ls( envir=.GlobalEnv ) ) Best regards, Carlos J. Gil Bellosta http://www.datan

Re: [R] R version of SAS/IntrNet

2010-05-14 Thread Carlos J. Gil Bellosta
I would recommend Rapache. I have tested it and it works great. SAS/Intrnet is just CGI with another name. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On 05/12/2010 06:27 PM, Mark Lamias wrote: Does an R package exist that is similar to SAS/Intrnet (http

Re: [R] Paste in a FOR loop

2008-12-31 Thread Carlos J. Gil Bellosta
?eval Carlos J. Gil Bellosta http://www.datanalytics.com __ 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

Re: [R] Package installation

2008-12-31 Thread Carlos J. Gil Bellosta
Why don't you post your message in the Bioconductor list? People there will be able to help you better. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2008-12-31 at 08:00 -0500, jianying...@med.unc.edu wrote: > Dear all, > > I tried to install biocon

Re: [R] How do I plot multiple XY plots on the same graph

2009-01-01 Thread Carlos J. Gil Bellosta
Hello, You can use plot for the first plot and points for the subsequent ones. Points will add new points to the existing plot reusing the axes, labels, etc. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2008-12-31 at 15:36 -0800, George Chen wrote: > Hello,

Re: [R] the first and last observation for each subject

2009-01-02 Thread Carlos J. Gil Bellosta
Hello, First, order your data by ID and time. The columns you want in your output dataframe are then unique(ID), tapply( x, ID, function( z ) z[ 1 ] ) and tapply( y, ID, function( z ) z[ lenght( z ) ] - z[ 1 ] ) Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Fri

Re: [R] the first and last observation for each subject

2009-01-02 Thread Carlos J. Gil Bellosta
Hello, Is is truly y=max(y)-min(y) what you want below? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Fri, 2009-01-02 at 13:16 -0500, Stavros Macrakis wrote: > I think there's a pretty simple solution here, though probably not the > most efficient: > &g

Re: [R] Equivalent of match for data.frame

2009-01-03 Thread Carlos J. Gil Bellosta
Hello, Why not something like lapply(mydf, function(x) match(myarg, x) ) ? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Sat, 2009-01-03 at 07:24 -0500, Sébastien wrote: > Dear R-users, > > I am translating a S script into R and having some troubles with the

Re: [R] if statement

2009-01-05 Thread Carlos J. Gil Bellosta
Hello, If you do C <- A C[A > X & A < Y] <- 0 you get what it seems you want. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Mon, 2009-01-05 at 03:41 -0800, Shruthi Jayaram wrote: > A <- ts(rnorm(120), freq=12, start=c(1992,8))

Re: [R] Changing Matrix Header

2009-01-06 Thread Carlos J. Gil Bellosta
Hello, colnames( dat ) <- NULL will do the trick. Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-01-06 at 17:14 +0900, Gundala Viswanath wrote: > Dear all, > > I have the following matrix. > > > dat > A A A A A A A A A A > [1,] 0 0 0 0

Re: [R] rbind for matrices - rep argument

2009-01-07 Thread Carlos J. Gil Bellosta
:5, function(x) kk ) do.call(rbind, kkk) You can write your code in a single line, though. I used 5 here as a matter of example. You can build a function on these lines with an arbitrary argument if need be. Carlos J. Gil Bellosta http://www.datanalytics.com > Niccol > > [[altern

Re: [R] VCOV Source Code

2009-01-08 Thread Carlos J. Gil Bellosta
Hello, You can do stats:::vcov.lm to see the source code for that particular method. In order to see which are the methods supported by vcov, write methods("vcov") Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2009-01-07 at 21:37 -0600, Yang Wan wrote

Re: [R] Dataframe with unequal rows

2009-01-08 Thread Carlos J. Gil Bellosta
Hello, You are not very precise there. Do you mean that the rows in your text file do not all have the same number of separators (commas, in your case)? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Thu, 2009-01-08 at 04:38 -0500, rahul-a.agar...@ubs.com wrote: > I h

Re: [R] VaR-Monte carlo Simulation, Historic simulation, Variance-Covariance Simulation

2009-01-08 Thread Carlos J. Gil Bellosta
Yes, there are: replicate and quantile are your friends. You will find better support in the R-Finance list, though. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Thu, 2009-01-08 at 01:36 -0800, Maithili Shiva wrote: > Dear R helpers > > Suppose I have a por

Re: [R] R in the NY Times

2009-01-08 Thread Carlos J. Gil Bellosta
be able to do) this with SAS... So, the number of downloads from CRAN servers seems like a lousy proxy for the total number of users of SAS. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://s

Re: [R] R in the NY Times

2009-01-08 Thread Carlos J. Gil Bellosta
n "how to compete" against R. The SAS salesperson statement in the article seems to have been extracted verbatim from them. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mai

Re: [R] Boxplot from matrices

2009-01-11 Thread Carlos J. Gil Bellosta
Hello, The following code may help you: > my.matrix <- matrix( rnorm(16), ncol = 4 ) > boxplot( my.matrix ~ col( my.matrix ) ) Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Sun, 2009-01-11 at 05:23 -0800, johnhj wrote: > Hii, > > I will create boxp

Re: [R] How to reference previous row?

2009-01-12 Thread Carlos J. Gil Bellosta
revious value. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Mon, 2009-01-12 at 18:57 +1100, Heston Capital wrote: > I am trying to write some code where the factor references its > previous value, but can't find a solution searching through the > archive. > &g

Re: [R] meaning of asymmetric on help page for intersect

2009-01-13 Thread Carlos J. Gil Bellosta
Hello, The symmetric set difference of A and B is the set of elements in A or B but not in A intersection B, i.e., ( (A U B) \ (A intersection B) ). The asymmetric set difference of A and B is the set of elements of A except those in B, i.e., (A \ B). Best regards, Carlos J. Gil Bellosta http

Re: [R] Comparing elements for equality

2009-01-13 Thread Carlos J. Gil Bellosta
Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-01-13 at 14:17 -0500, Doran, Harold wrote: > Suppose I have a dataframe as follows: > > dat <- data.frame(id = c(1,1,2,2,2), var1 = c(10,10,20,20,25), var2 = > c('foo', 'foo', '

Re: [R] Howto access object of object

2009-01-14 Thread Carlos J. Gil Bellosta
Hello, Use "@" instead of "$" to extract slots from a S4 object. Regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2009-01-14 at 17:07 +0900, Gundala Viswanath wrote: > Dear all, > > I have the following object: > > > print(x) > A

Re: [R] Vectorization of three embedded loops

2009-01-14 Thread Carlos J. Gil Bellosta
en you would be back into (1)). Creating a variable sum as c() and increasing its size in a loop is one of the easiest ways to uselessly burn your CPU. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2009-01-14 at 10:32 +0300, Thomas Terhoeven-Urselmans wrote: &g

Re: [R] Obtain numbers from vector of NAs and numbers

2009-01-14 Thread Carlos J. Gil Bellosta
Hello, new.dat <- dat[ ! is.na(dat) ] should do the trick. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Wed, 2009-01-14 at 19:32 +0900, Gundala Viswanath wrote: > Dear all, > > I have this set of vectors generated via a loop. > > > for (i in 1:nr

Re: [R] Value Lookup from File without Slurping

2009-01-16 Thread Carlos J. Gil Bellosta
ys store your repo.txt into a database, say, SQLite, and select only the values you want via an SQL query. Thus, you will prevent loading the full file into memory. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-proje

Re: [R] problem with applying where condition

2009-01-19 Thread Carlos J. Gil Bellosta
Hello, You can merge both tables first and then select the rows and columns you want. Do it the other way around if your tables are too big. All you need you can read it at ?merge ?subset Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-01-20 at 11:03 +0530

Re: [R] Merging tables

2009-01-20 Thread Carlos J. Gil Bellosta
Hello, Use merge. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-01-20 at 13:41 +, Dry, Jonathan R wrote: > I am relatively new to R and am trying to do some basic data manipulation. > Basically I have a table (csv - table 1) of data for a set of s

Re: [R] from matrix to data.frame

2009-01-20 Thread Carlos J. Gil Bellosta
Hello, The columns in your output dataframe are the following vectors: X1: as.vector( row(a) ) X2: colnames(a)[as.vector( col(a) )] X3: as.vector( a ) Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-01-20 at 15:10 +0100, Antje wrote: > Hello, >

Re: [R] Does anyone has this paper in pdf?

2009-01-23 Thread Carlos J. Gil Bellosta
et than it solves. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ 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

Re: [R] Mode (statistics) in R?

2009-01-26 Thread Carlos J. Gil Bellosta
Hello, You can try ?table. Best regards, Carlos J. Gil Bellosta http://www.datanaytics.com On Mon, 2009-01-26 at 05:28 -0800, Jason Rupert wrote: > Hopefully this is a pretty simple question: > > Is there a function in R that calculates the "mode" of a sample? That is, I

Re: [R] D'Hondt method

2009-02-04 Thread Carlos J. Gil Bellosta
n(x) x / 1:seats )) ) tmp <- tmp$candidates[order( - tmp$scores )] [1:seats] table(tmp) } > votes <- sample(1:1, 5) > votes [1] 448 7685 5445 482 6266 > dHont(letters[1:5], votes, 10 ) tmp a b c d e 0 4 3 0 3 Best regards, Carlos J. Gil Bellosta http://www.dat

[R] R Interface Coming to SAS/IML Studio

2009-02-05 Thread Carlos J. Gil Bellosta
Hello, I thought this link could be of interest to the list. http://support.sas.com/rnd/app/studio/Rinterface2.html Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

Re: [R] SAS Institute Adding Support for R

2009-02-13 Thread Carlos J. Gil Bellosta
che or other open source products they bundle along with their solutions. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] everybody loves R...

2009-02-20 Thread Carlos J. Gil Bellosta
lop the idea further. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Fri, 2009-02-20 at 09:59 +, UsuarioR España wrote: > Hi all > > This > topic is very interesting to me as I was planning to do something > similar, but in Spanish. In my opinion wi

Re: [R] modifying a built in function from the stats package (fixing arima)

2009-03-03 Thread Carlos J. Gil Bellosta
several ways to go, among them: 1) Copy the existing function into a new file, edit it and load it via source. 2) Download the source package and modify it for your own purposes. Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Tue, 2009-03-03 at 18:20 +0100, Marc Vinyes wrote

Re: [R] Fast Fourier Transform w.r.t. CreditRisk+

2009-03-05 Thread Carlos J. Gil Bellosta
Hello, You have a link on the subject here: http://papers.ssrn.com/sol3/papers.cfm?abstract_id=1122844 The author has extra literature and code on the subject. Also, there was a thread in R-SIG-Finance list on the subject a few months ago. Best regards, Carlos J. Gil Bellosta http

[R] Describing clusters

2009-03-18 Thread Carlos J. Gil Bellosta
I could review this output and say: this cluster corresponds to, say, "older patients who were not treated before", etc. I am aware this is not sound scientific practice, but I am asked to do something like that. I have some ideas about how to do it, but I would like to know if I am walkin

[R] Describing clusters

2009-03-18 Thread Carlos J. Gil Bellosta
I could review this output and say: this cluster corresponds to, say, "older patients who were not treated before", etc. I am aware this is not sound scientific practice, but I am asked to do something like that. I have some ideas about how to do it, but I would like to know if I am walkin

Re: [R] How do you apply a function to each variable in a data frame?

2008-11-03 Thread Carlos J. Gil Bellosta
Data frames are lists themselves. Something like do.call( rbind, lapply( my.data.frame, quantile, probs=c(0.1,0.9)) ) should work. Carlos J. Gil Bellosta http://www.datanalytics.com On Mon, 2008-11-03 at 07:03 -0800, zerfetzen wrote: > I want to apply a more complicated function than wha

Re: [R] CROSSTABULATION

2008-11-13 Thread Carlos J. Gil Bellosta
Hello... Which code are you using to perform the breakup into the three classes? Can you be more specific on that? Best regards, Carlos J. Gil Bellosta http://www.datanalytics.com On Thu, 2008-11-13 at 09:57 +, Sohail wrote: > I want to form a 3x3 crosstabulation for the signs of