Questions tagged [r.net]

For questions about R.NET (rdotnet), which allows interoperability between the .NET Framework and the R language for statistical computing.

R.NET enables the .NET Framework to interoperate with the R statistical language in the same process. It requires .NET Framework 4 and the native R DLLs to be installed with the R environment.

R.NET works on Windows, Linux, and macOS.

180 questions
0
votes
1 answer

EEG data preprocessing with mne python

I have Physiological EEG emotion dataset named "Deap". I want to analyze and visualize the data through MNE but it has its own format. How can I load my personal data for pre-processing, data format is (.dat)?
Zeedin
  • 1
  • 1
0
votes
1 answer

R.NET and Microsoft R Open I can't use package xlsx

I'm just starting with R.Net and Microsoft R Open. So far I have been successful with simple tests but I am now trying to convert a .rda file to an Excel spreadsheet. I have the following code: REngine engine = REngine.GetInstance(); …
user1047857
  • 133
  • 1
  • 11
0
votes
2 answers

Load xlsx package using R.NET

I'm trying to load the xlsx package to read the excel file engine.Evaluate("load(xlsx)"); However, an stackoverflow exception is thrown. So, do we have any ways to load a R package or how can we read an excel file using r.net ? Thank you.
Phong Vo
  • 1,078
  • 7
  • 16
0
votes
2 answers

How to save a plot generated via R.NET to a file on disk?

I am using R.NET to generate plots (using ggplot) and I want to save these graphs in PNG format on disk. Whenever I call engine.Evaluate("ggsave('C:\path\to\file.png', myPlot)") the program abruptly aborts with exit code 2 without anything being…
Hunter2
  • 35
  • 1
  • 8
0
votes
1 answer

Unicode characters returning from R.NET

I'm returning a Character vector from a function in R to C# using R.NET. The only problem is that unicode characters, such as Greek Letters are being lost. The following line gives an example of the code I'm using: CharacterVector cvAll =…
Jennifer B
  • 38
  • 6
0
votes
1 answer

R DataFrame object with WCF

I have a very vague understanding of WCF but after a bit of research I figured out that WCF does not like handling custom objects. I am looking for a feasible workaround. This is my objective. I aim to create a WCF service that accepts certain…
0
votes
0 answers

Executing .R script with RGL Plott from c# Gui via RScripRunner Class

I have a PointCloud with XYZ-Data and want to plot it via a .r script from my C# GUI. Therefore i use the "rgl" library in R. The R code works fine. I try to use this class: /// /// This class runs R code from a file using the console. ///…
Quirin Kraus
  • 131
  • 1
  • 1
  • 5
0
votes
0 answers

How to print R evaluation in RDotNet

I test a simple code in R-Gui but I don't know how print same result in RdotNet via c#. library(ISLR) data(Auto) attach(Auto) reg<- lm(mpg~horsepower) summary(reg) The result is : Call: lm(formula = mpg ~ horsepower) Residuals: Min 1Q …
0
votes
1 answer

Rengine.GetInstance() shows error

While connecting R from windows application on VS2015 framework 4.6, Its working fine. But when the same code i have added to webservice it throws an exception System.NullReferenceException' occurred in RDotNet.dll but was not handled in user code…
Viswa
  • 169
  • 1
  • 4
  • 11
0
votes
1 answer

How to acess an R project (RTVS) from a C# project in VS 2017 with RDotNet?

Simply put, I want to make a C# front-end for an R project. Ellaborating a bit: I want to use a function I define in an R project (RTVS) in my C# code using RDotNet, but extensive search in Google yielded no results (by the way, it seems that even…
0
votes
0 answers

Finding Max and Min of a Polynomial conic equation

This is an effort to detect and fit a set of points to an ellipse. I have a method to take x,y data and generate a conic formula, but due to the nature of the polynomial there are 2 solutions for Y Example: 1x² +-0.008xy +0.976y² + -316.916x…
0
votes
0 answers

System.StackOverflowException when trying to reference SASxport library

I am trying to use RDotNet to create a SAS v5 transport file, my script runs fine in R but when I try to reference the library via the RDotNet engine.Evaluate("library(SASxport)") I get a System.StackOverflowException. This is not happening for…
user1641172
0
votes
1 answer

How do I break long line in RDotNet?

How can I do to break the long line of my R scripts used to run in c#? For example, if I have this code: engine.evalute("f.rf=function(i) { NBR_ACH<-ALL_DATA[-intrain,1] set.seed(7)…
Rprogrammer
  • 457
  • 2
  • 6
  • 19
0
votes
2 answers

Running external libraries with R.net in IIS

We're trying to run R.net from an ASP.Net webpage in IIS, but encounter the problem that the R engine can't access external libraries. I know this is a common problem, but the typical solutions haven't worked when it comes to IIS (only IIS express…
0
votes
1 answer

Even I find the logical solution of the error "y must have at least 2 data points" , It doesn't work

After I prepare my data base as shown in the code below, I tried to split the data into training and testing. So I uesd createDataPartition function to do this. My R scripts in c#: // the data base DataFrame BASE =…
User2018
  • 61
  • 10