[R] GA package integer hyperparameters optimization

2017-04-10 Thread AURORA GONZALEZ VIDAL
Hello everybody. I am  using the GA package[1] in order to optimize the hyperparameter of SVM like in this example is done: http://stackoverflow.com/questions/32026436/how-to-optimize-parameters-using-genetic-algorithms However, when I try to adapt the example for random forest, it takes very ver

[R] optimize the filling of a diagonal matrix (two for loops)

2016-08-18 Thread AURORA GONZALEZ VIDAL
Hello I have two for loops that I am trying to optimize... I looked for vectorization or for using some funcions of the apply family  but really cannot do it. I am writting my code with some small data set. With this size there is no problem but sometimes I will have hundreds of rows so it is real

[R] dissimilarity matrix using SAX distance

2016-08-16 Thread AURORA GONZALEZ VIDAL
Dear all, I'm trying to cluster some data using SAX distance that was described in the paper "a symbolic representation of time series with implications for streaming algorithms" http://www.cs.ucr.edu/~eamonn/SAX.pdf Once I have my data in matrix format, which function can I use to compute the di

[R] evaluation + Re: hourly prediction time series

2016-02-07 Thread AURORA GONZALEZ VIDAL
-Original Message- > From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of AURORA > GONZALEZ VIDAL > Sent: 05 February 2016 10:50 AM > To: r-help@r-project.org > Subject: [R] hourly prediction time series > > Dear R users, > > I am fronting my firts tim

[R] hourly prediction time series

2016-02-05 Thread AURORA GONZALEZ VIDAL
Dear R users, I am fronting my firts time series problem. I have hourly temperature data for 3 years (from 01/01/2013 to 5/02/2016). I would like to use those in order to PREDICT TEMPERATURE OF THE NEXT HOURS according to the observations. A subset of the data look like this: date <- rep(seq(as

[R] predictions several categories

2015-10-12 Thread AURORA GONZALEZ VIDAL
Hello everybody. I am using the caret package in order to predict something from some data. I have "hours" , "days" and "temperature" where "hours" are given in decimal form, "days" are the days of the week where each observation was colected and "temperature" is the temperature that a user of air

[R] compare grupos dichotomus dependent variable

2015-08-07 Thread AURORA GONZALEZ VIDAL
Hello everybody. I have a statistics question: let's say that I want to compaire answers between men and women to a yes/no question but I have so much more women than men, then, it looks like I cannot use chi squared test. Would it be correct to use U test (or ranked Wilcoxon test)?? What do you t

[R] graphviz, Rmarkdown, colorBrewer

2015-07-26 Thread AURORA GONZALEZ VIDAL
Hello. I am drawing a graph using graphviz. It works but now, I am trying to use some palettes from the RColorBrewer pakcage. Any idea why this diagram works when the code (in .Rmd) is ```{r, engine='dot', echo=F} digraph unix{   size=30;   ratio=compress;     param [label="  Contrastes paramétric

[R] rgl 3d surface

2015-07-15 Thread AURORA GONZALEZ VIDAL
Hello. I am trying to plot a 3d surface given its equation. The R code is written in blue. So, let's say that I have the points x,y,z and I plot them. Also, I compute its regression surface doing polynomical regression (fit) library('rgl') x <- c(-32.09652, -28.79491, -25.48977, -23.18746,-20.889

[R] Rmarkdown / knitr naming the output file

2015-07-06 Thread AURORA GONZALEZ VIDAL
Hello. I have a question for Rmarkdown users. Is there any way to give a name to the output document inside the Rmd? For example, my rmd's name is "bb.Rmd" but when I knitr to pdf I want it to name the pdf differently than "bb.pdf", for example, "doc1.pdf". Is there any way to do this? Thank you

[R] geom_text in ggplot (position)

2015-05-12 Thread AURORA GONZALEZ VIDAL
Hello everybody. I have an "esthetic" question. I have managed to create a stacked and grouped bar plot but I don't manage with putting the text in the middle of the bar plots. Do you know how to write the numbers in that position? Thank you so much. Example code: test  <- data.frame(variables

[R] xtable caption knitr

2015-02-24 Thread AURORA GONZALEZ VIDAL
Dear all, I have a problem with the caption option on the xtable function. Using Rmarkdown, knitr generates correctly a pdf when I write something like this: ```{r xtable, results="asis"} library( xtable ) variableName  <- c( "V03_1" ) age <- c( rep(1,10),rep(2,10),rep(3,10) ) gender <- c( rep("m

[R] Rstudio and GIT

2015-01-14 Thread AURORA GONZALEZ VIDAL
Dear R users, I have a  very specific question. I want to know how to create a local git repository from an exisitng file (with some documents inside) just like we do when typing git init but from Rstudio. I tried selecting FIle-->New Project-->Existing Directory--> and I select the file but I