[R] Model after random forest

2015-09-13 Thread jpara3
Hi there, I´m using random Forest package to create a random Forest: model<-randomForest(A~.,data=mydata) , and I use the varImpPlot(model) to see which are the most important variables, so I obtain that C, D and F are the most important ones, but... How can I see the model, in which levels I

Re: [R] removing outlier

2015-09-13 Thread Bert Gunter
... and this, of course, is a nice example of how statistics contributes to the "irreproducibility crisis" now roiling Science. Cheers, Bert (Quote from a long ago engineering colleague: "Whenever I see an outlier, I never know whether to throw it away or patent it.") Bert Gunter "Data is not

Re: [R] a question about data manipulation in R

2015-09-13 Thread Michael Dewey
Dear Zahra Your email is completely unreadable because you posted in HTML. Please reset your mailer and try again. On 13/09/2015 06:12, Zahra Karimi via R-help wrote: Hello, I have a data like this:1 2331 3331 4551 3452 5432 4332 3442 4003 4443 1113 0003 432I want to change it to this new

Re: [R] For logical i and length(i) > length(x), x[i] <- value makes length(x) == length(i)

2015-09-13 Thread Suharto Anggono Suharto Anggono via R-help
Thank you for looking. If the last element of i is TRUE, the largest value of which(i) is length(i). So, even if x[i] <- value were translated to x[which(i)] <- value, the result would have length(x) == length(i). Difference between x[i] <- value and x[which(i)] <- value in R would occur when

[R] Please read **Urgent** Need help with R

2015-09-13 Thread Mehmet Doğan
Dear All, I can NOT format and create an xts object of my data in order to forecast Volatility. Moreover I can NOT plot the data. basically i cant work with the data i have. I need to finish my project till tomorrow. Could you please help me with those problems? I also attached my data. the

Re: [R] Exporting from R to Excel or .csv

2015-09-13 Thread Ryan Shuell
This is my first time posting here library(BradleyTerry2) library(xlsx) data(flatlizards) str(flatlizards) a <- data.frame(x=rnorm(10), y=runif(10)) b <- data.frame(w=rnorm(20), z=runif(20)) ablist <- list(a, b) write.xlsx(mydata, "c:/Test/mydata.xlsx") On Tuesday, June 16, 2015 at

Re: [R] Please read **Urgent** Need help with R

2015-09-13 Thread John Kane
Hi Mehmet, Did you send this in HTML? That's what it looks like. It is currently almost unreadable. You need to reformat it and send it as plain text. You need to reduce the code to the key parts if possible. It looks like most of the code is unneeded for the problem and is just a distraction.

Re: [R] For logical i and length(i) > length(x), x[i] <- value makes length(x) == length(i)

2015-09-13 Thread William Dunlap
>>From it, I infer that, if i is logical and length(i) >= length(x), x[i] <- >>value has >the same effect to x[which(i)] <- value, where which(i) takes >>indices where i is >T. The return value of which(i) gives only the indices of the TRUE values in i. It does not return the length of i.

Re: [R] a question about data manipulation in R

2015-09-13 Thread John Kane
You are in the right place but the question in not very clear. Have a look at the links below for some suggestions on how to ask a question on R-help. I think we need the data in dput() format. See ?dput or the discussion of dput() in the links.

Re: [R] kendall tau distance

2015-09-13 Thread David L Carlson
The function takes a two way table. Assuming your example involves two ordinal vectors c(1,2,3,4,5) and c(3,4,1,2,5), you need: > xy <- table(c(1,2,3,4,5),c(3,4,1,2,5)) > xy 1 2 3 4 5 1 0 0 1 0 0 2 0 0 0 1 0 3 1 0 0 0 0 4 0 1 0 0 0 5 0 0 0 0 1 > cd <- ConDisPairs(xy) > cd $pi.c

[R] a question about data manipulation in R

2015-09-13 Thread Zahra Karimi via R-help
Hello, I have a data like this:1 2331 3331 4551 3452 5432 4332 3442 4003 4443 1113 0003 432I want to change it to this new dataset:c1    c2     c3233  543  444333  433  111455  344  000345  400  432  How can I do this in R? Please if this not the correct place to ask  my queston.. then could

[R-es] Rv: para una pequeña orientación

2015-09-13 Thread heber sarmiento via R-help-es
El Sábado, 12 de septiembre, 2015 12:07:55, heber sarmiento escribió: Cordial saludo a todos: Estoy realizando un script en el que se deben leer algunos datos, para esto he escrito el siguiente códigocat("introducir los datos:")x<-scan()cat("los datos

[R] Please read **URGENT** Need help with R

2015-09-13 Thread Mehmet Dogan
library(xts) library(zoo) EURUSD<-read.csv("Data_Forecast/EURUSD.csv") # to load the data EURUSD<-read.csv("Data_Forecast/EURUSD.csv",stringsAsFactors=F) # to load as a factor #?? EURUSD$Date<-as.Date(EURUSD$Date,format="%Y-%m-%d" , "h:m:s") # here the code is not working to

[R] Problem solved

2015-09-13 Thread B Jessop
Further to my posting re: extracting case values from ancova adjusted means, I have solved the problem. Regards, Brian Jessop [[alternative HTML version deleted]] __ R-help@r-project.org mailing

Re: [R] Please read **Urgent** Need help with R

2015-09-13 Thread Rolf Turner
On 14/09/15 00:31, Mehmet Doğan wrote: Dear All, I can NOT format and create an xts object of my data in order to forecast Volatility. Moreover I can NOT plot the data. basically i cant work with the data i have. I need to finish my project till tomorrow. Could you please help me with those

Re: [R-es] Una pequeña consulta urgente

2015-09-13 Thread David Suárez via R-help-es
Hola, cat no te captura los valores, solamente escribe el mensaje en la consola. Podrías hacer lo siguientes: cat("Ingresa el valor"); x<-scan(); cat("los valores ingresados son", x, "\n"); Espero te sirva El vie., 11 de sept. de 2015 a la(s) 4:50 p. m., heber sarmiento via R-help-es

Re: [R] How to read CSV from web?

2015-09-13 Thread Ryan Shuell
How about this? library(XML) library(RCurl) url <- "https://raw.githubusercontent.com/sjkiss/Survey/master/mlogit.out.csv; urldata <- getURL(url) data <- readHTMLTable(urldata, stringsAsFactors = FALSE) On Wednesday, July 29, 2015 at 6:41:35 AM UTC-4, jpara3 wrote: > > data<-read.csv("

Re: [R] How to read CSV from web?

2015-09-13 Thread Ryan Shuell
Also, you should bookmark this link. http://www.r-bloggers.com/this-r-data-import-tutorial-is-everything-you-need/ On Wednesday, July 29, 2015 at 6:41:35 AM UTC-4, jpara3 wrote: > > data<-read.csv(" > https://raw.githubusercontent.com/sjkiss/Survey/master/mlogit.out.csv",header=T,sep=",;) >

[R] adding a line across plots in xy plot with panel.abline

2015-09-13 Thread Christine Lee via R-help
Dear all, I want to draw a line at DI=1 across all four graphs in the xy plot, I have used panel.abline, but I failed to do so, does any one has an idea of what has went wrong? structure(list(Date = structure(c(6L, 7L, 2L, 4L, 13L, 17L, 5L, 12L, 4L, 11L, 14L, 9L, 7L, 2L, 4L, 13L, 10L, 17L,

Re: [R] removing outlier

2015-09-13 Thread David Winsemius
If this mailing list accepted formatted submissions I would have used the trèsModernSarcastic font for my first sentence. Failing the availability of that mode of communication I am (top) posting through Nabble (perhaps) in "Comic Sans". On Sat, Sep 12, 2015 at 9:52 AM, David Winsemius