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
2 answers

How to construct F# tuple type?

Given the following type in F# type Message = string * AsyncReplyChannel How can I construct it ? Great stuff over at F# for fun and profit, but I cannot find how to construct the new 'algebraic data type' Message. Here's what…
Jochen van Wylick
  • 5,303
  • 4
  • 42
  • 64
0
votes
0 answers

How to fill my method from the list or from my db?

I have this method public void RPlot(String var1, String Var2) { REngine.SetEnvironmentVariables(); REngine engine = REngine.GetInstance(); engine.Initialize(); String RCommand = "plot(" + var1 + "," + Var2 + ")"; …
user4203128
0
votes
1 answer

Data frame handling in C# connected with R

I am trying to handle a dataframe in R through a WPF application. I have used RDotNet as an interface between R and C# and my code snippet is as follows DataFrame mapp = engine_1.Evaluate("mapp").AsDataFrame(); I am unable to get specific columns…
0
votes
1 answer

Using R.NET with multiple AppDomains

Is it possible to use R.NET from multiple AppDomains? At the end of the documentation there is a reference to "Multiple app domains", but no further information. The scenario is that I have what is essentially a trading system IDE. Each time a…
Daniel Plaisted
  • 16,674
  • 4
  • 44
  • 56
0
votes
2 answers

Bind strings with quotation

I am sending some code to R.net wrapper as strings. If there are no any quation marks inside , it's simple with @ engine.Evaluate(@"remove_outliersabove <- function(x, na.rm = TRUE, ...) { qnt <- quantile(x, probs=c(.25,…
kosnkov
  • 5,609
  • 13
  • 66
  • 107
0
votes
1 answer

R. net read file exception

I wrote the following code: REngine.SetEnvironmentVariables(); REngine engine = REngine.GetInstance(); engine.Evaluate("dataset<-read.table('C:\\Users\\b-mobela\\Documents\\Temp\\data.txt')") I get the exception: "An unhandled…
0
votes
1 answer

How to call a user defined function (in a .rdata file) from c# R.net?

I have, in one hand, a plateform I developped in R, composed of many user-defined functions used to produce a report, using as inputs matrices and arguments. In an other I manage my data flow through a c# Platform. What I want to do is calling my R…
ylnor
  • 4,531
  • 2
  • 22
  • 39
0
votes
1 answer

R (D)COM how to import c# arrays into R to apply some R algorithms on it

I have read about importing data from a text file into R and processing that data and saving it into a c# variable using R (D)COM. But what i want to do is - import a c# array/list into a r variable and perform the processing on this array. I've…
sadhana
  • 157
  • 1
  • 2
  • 11
0
votes
0 answers

resizing plots generated using R.Net causes application to crash

I'm using R.Net library. This is my sample code: REngine.SetEnvironmentVariables(); REngine engine = REngine.GetInstance(); engine.Evaluate("cars <- c(1, 3, 6, 4, 9)"); engine.Evaluate("plot(cars)"); And the chart appears but when I try to resize…
gruber
  • 28,739
  • 35
  • 124
  • 216
0
votes
1 answer

How to access a variable of class ets in c# while using RdotNet

fit<-ets(myts) where myts is a time series defined using ts() function.Now i want to read the output parameters like smoothing parameters alpha, beta and initial states and model type chosen by ets() function(eg: (A,N,N))... How do i do that in c#?…
sadhana
  • 157
  • 1
  • 2
  • 11
0
votes
1 answer

Multi-windows R graphs in C# with RDotNet

I have a C# code for a simple windows form with 3 buttons. Button 1 calls R and plots a surface while button 2 plots a contour. If I launch the application and click on button 1, I correctly see the surface plot but then I would like to click on…
opt
  • 477
  • 1
  • 10
  • 25
0
votes
1 answer

Extract x,y values from deldir object using RDotNet

Background I am using RDotNet to run an R script that performs a voronoi tessellation using the deldir package. After R:tiles = tile.list(voro) I wish to extract R:tiles[[i]][c("x","y")] for the each tile i into a…
JustinJDavies
  • 2,663
  • 4
  • 30
  • 52
0
votes
1 answer

ParseException error in R when called from RDotNet

Having progressed my initial test of getting c#, R to work in our MVC web environment. I was trying to get the following code to work (taken from -> http://rdotnet.codeplex.com/) To investigate this so far I have launched R from a cmd prompt and…
julian guppy
  • 411
  • 1
  • 4
  • 21
-1
votes
2 answers

Way to avoid mentioning the data type in c# when R function is called using RdotNET

I am calling R functions in C# using R.NET. While doing that I realized that every time I call a function I need to specif its type. For Instance: engine.Evaluate("x = 3.5:10.5"); NumericVector a1=…
Artiga
  • 776
  • 2
  • 16
  • 37
-2
votes
2 answers

How can I see the output of command line in cs file

I am working in .cs file and I need to see the output of some object/variable executed by the c# program. I will use that for debbuging purposes each time. For example, in the code below, I need to see the output of the variable DataNaiss…
User2018
  • 61
  • 10
1 2 3
11
12