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

How to interpretate my solutions? (t-test, corelation coefficients) [migrated]

I am pretty new in R and I do not know how to interpretate my solutions. I have meteorological data (daily temperatures) of two meteorological stations in the same city. I did t.test, wilcox.test and...

View Article


decision tree implementation code in R: repository or library?

I'm very very new in R. I'm looking for the code in R where I can see the full implementation of the algorithm. In particular, I need it because I'm creating a new split criterion and I like to create...

View Article


Is it a good practice to call functions in a package via ::

I'm writing some R functions that employ some useful functions in other packages like stringr and base64enc. Is it good not to call library(...) or require(...) to load these packages first but to use...

View Article

"NaNs produced" warning when calculating absolute EC50 values with drc package

I'm trying to figure out how to calculate absolute EC50 values using the LL.3 and LL.4 (3 and 4 parameter) dose response models in the package drc, but I keep getting these errors of "Warning...

View Article

Image may be NSFW.
Clik here to view.

Create %-contour in a 3d kernel density and find which points are within that...

I want to plot the isosurface of a specific %-contour in a 3d kernel density estimate. Then, I want to know which points are within that 3d shape.I'll show I approach the 2d situation to illustrate my...

View Article


How to calculate the maximum and minimum value in R?

1.Use the function hav_dist() to create the column my_distance. 2.Create the column diff which is the difference between my_distance and trip_distance. 3.Find the minimum and the maximum of the diff...

View Article

R Read (Excel, txt...) rows and columns with conditions

Supose I have this dataframe in a .dta, .txt or excel file:ID fondo 1 colf 2 colf 3 prot 4 colf 5 porv 6 prot 7 porv 8 colf 9 colf 10 colf I would like to read this file just the column 1 (ID) and the...

View Article

What is the code to know which words are different between two dfm?

I have two dfm and I would like to know which words are missing/different between them. For example,df1 <- data.frame(Text = c("Stackoverflow is a great place where very skilled data scientists are...

View Article


How to install 'quantmod' package in R on os UBUNTU?

> install.packages("quantmod") Installing package into ‘/home/yugandhar/R/x86_64-pc-linux-gnu-library/3.6’ (as ‘lib’ is unspecified) also installing the dependencies ‘xts’, ‘zoo’, ‘TTR’ trying URL...

View Article


How can I add sections to a web page made from a Rmarkdown file that spans...

Is there a way to add sections with different background color to a web page made in Rmarkdown? I haven't been able to come up with a way to do this, but I try to add a Bootstrap jumbotron by adding an...

View Article

How to exclude patients in R based on number of readings?

I'm struggling with a particular aspect of filtering my data. I have a table that records about 300 parameters for about 8000 patients over the course of a study. I can already filter for those without...

View Article

Time series in R in column

I do have time series with months in rows instead of columns. It's quite a large dataset and I am looking for a way to get the mean for every 12 rows, in this case for temperature so that a smaller...

View Article

R studio, how to check if number in vector is ODD or EVEN

Say you have:vector <- c(1,2,3,4,5) Using if else statements, and a for loop - how can I check if the number is ODD in the if statemnt?

View Article


Image may be NSFW.
Clik here to view.

How to use ARIMA.SIM with an existing TimeSeries

I am trying to use arima.sim to plot it and then Add fractdiff.sim to the plot.I am able to use arima.sim but I don't know how to specify the time series I want to use (Total_TimeSeries) :...

View Article

Image may be NSFW.
Clik here to view.

set axes limits in patchwork when combining ggplot2 objects

When combining ggplot2 objects using patchwork I would like to be able to have an option that I could easily set an option for all the plots to have the same x-axis and/or y-axis...

View Article


Using approx function within tapply or by in R

I have a temperature profiler (tp) data for date, depth and temperature. The depth for each date is not exactly the same so I need to unify it to the same depth and set the temperature for that depth...

View Article

How to convert .fmt file to .txt file

I am doing computations with GAUSS/Aptech, and I just use 'save' syntax to save the results.Then the results are saved in .fmt format.I guess there must be some GAUSS' syntax(or functions) which can...

View Article


Caching a huge data table with knitr

I am trying to cache a big data.table and then make a plot out of it, the code is as follow:{r gen-data, tidy=TRUE, warning=FALSE, tidy.opts=list(width.cutoff=60), cache = TRUE, cache.lazy=FALSE} DT =...

View Article

Non-redundant version of expand.grid

The R function expand.grid returns all possible combination between the elements of supplied parameters. e.g.> expand.grid(c("aa", "ab", "cc"), c("aa", "ab", "cc")) Var1 Var2 1 aa aa 2 ab aa 3 cc aa...

View Article

Error using predict() on a bsts object in R: incompatible covariates in...

I'm training a forecasting model using the bsts package in R. No matter what number of covariates I include in the model, I'm getting the following error:I'm not having any other problems with my bsts...

View Article
Browsing all 201839 articles
Browse latest View live


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