Quantcast
Channel: Active questions tagged r - Stack Overflow
Browsing all 206180 articles
Browse latest View live
↧

How to implement multi-branch regression trees in R

Is it possible to do the multi branch regression trees(non binary split) using R?

View Article


How do I get my shinyApp to read in my data file?

I have my server.R, ui.R and csv file all in my github repo. When I run my shinyapp from R using shiny::runGitHub("st558projectfinal","cgcomora") I get an error that object 'crimes' can't be found. Any...

View Article


How to create a function that plots radials in R?

I have never plotted a radial in R before, so I have no idea what I am doing. Is there a different type of plot I should be using? Also I have a list of r's and theta's, however I am not sure how to...

View Article

How do I extract estimates and standard errors as a measure of linear...

Let's say I have data:data = data.frame(xdata = 1:10, ydata = 6:15) I look at the datadata xdata ydata 1 1 6 2 2 7 3 3 8 4 4 9 5 5 10 6 6 11 7 7 12 8 8 13 9 9 14 10 10 15 Now I want to include a third...

View Article

Adding comment to a JIRA issue ticket using REST API in R

I would like to add more comments to an existing JIRA ticket using REST API pro grammatically from RI tried the following based on this link in this forum but did not work:library(httr)...

View Article


Is there a way to handle the first lapply element differently? or prepend it...

Is there a way to handle the first lapply element differently? or prepend it to the lapply result on the subsequent elements?For example, I have the following:mapping <- c("a", "b", "c") # this...

View Article

Add a new level of a variable and asign it the mean value of other variables...

I want to add a level of a variable in a data frame and asign it the average value of other levels in the same variable. I dont know how to do this. So, I want to add the level "base" in the variable...

View Article

Assigning plot to a variable in a loop

I am trying to create 2 line plots.But I noticed that using a for loop will generate two plots with y=mev2 (instead of a plot based on y=mev1 and another one based on y=mev2).The code below shows the...

View Article


Alternate elements of a vector with multiple NAs

I have a character vector in R, and want to make a new vector with multiple NAs between the elements of the character vector. To simplify, the character vector is:cv <- c( "A", "B", "C" ) Let's say...

View Article


Seperating columns with a vertical line and adding a footnote in an Xtable...

I was wondering if anyone knows how to add a footnote beneath an Xtable, as well as seperating each column with a vertical line to make this table look a bit neater.I would like my footnote to say...

View Article

How to make a time series in R by counting entries from a given vector?...

This question already has an answer here:Counting unique / distinct values by group in a data frame 10 answersHow do I group my date variable into month/year in R? 6 answersI have a vector like...

View Article

How do I fit a Gaussian curve to this data? [duplicate]

This question already has an answer here:Fitting a normal distribution in R 2 answersHow to fit normal distribution with respect to frequency and intensity in R? 1 answerI'm new to R and am trying to...

View Article

How to save a `quosure` to be used in another session?

What's the best way to save a quosure so that it can be run on another session? Consider the below, which uses the {rlang}'s quosure concept to quote an expression x+2 and captures its environment...

View Article


Taking for loop results to a dataframe

Im running this code:#Importar los datos boyanza <- read_excel("Desktop/Tesina - Boyanza del ITBIS/Data/Data ITBIS:PIB Trimestral.xlsx") boyanza <-...

View Article

linear regression for time series in r- efficiently

Customer date sales1 sales2 c1 2019-01-01 67 35 c1 2019-01-07 70 32 c1 2019-01-14 72 40 c2 2019-01-01 100 12 c2 2019-01-07 134 20 c2 2019-01-14 174 23 Making date column as number for forecasting...

View Article


Image may be NSFW.
Clik here to view.

Counts of rows in data table based on values

I want to rank each hour value within each individual id. The hour values that equal each other will be the same rank. I attempted to do this with the row count function (.N) in data.table. I was...

View Article

Image may be NSFW.
Clik here to view.

Grouped Bar Chart Plotly

I am trying to use plotly to make a bar chart using the following data:Any help on this is appreciated. I want it to look similar to this graph but instead of men and women it has the year or income as...

View Article


How to calculate RMSE of a vector of parameters?

I have a model with 4061 parameters in which there are 6 number of 10x1 vectors, 2 number of 2000x1 vectors and a scalar parameter.For each vector (or scalar) parameter, I do have a true vector and an...

View Article

How to fix incompatible arguments mvrnorm?

So I have to impute data for my Stats course. This works like a charm with the example we did in class. But the second I do it with this data, I get an "incompatible arguments" with the mvrnorm...

View Article

do.call(rbind, list) for uneven number of column

I have a list, with each element being a character vector, of differing lengths I would like to bind the data as rows, so that the column names 'line up' and if there is extra data then create column...

View Article
Browsing all 206180 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>