Quantcast
Channel: R.NET
Viewing all articles
Browse latest Browse all 1634

Commented Unassigned: Cannot call base package functionality in r [116]

$
0
0
Hi!

I have installed R.NET version 1.5.12, also tried version 1.5.11. I am simply trying to make the simple eample with the t-distribution test work.

Simple operations work fine, such as

NumericVector group1 = engine.CreateNumericVector(new double[] { 30.02, 29.99, 30.11, 29.97, 30.01, 29.99 });
engine.SetSymbol("group1", group1);
// Direct parsing from R script.
NumericVector group2 = engine.Evaluate("group2 <- c(29.89, 29.93, 29.72, 29.98, 30.02, 29.98)").AsNumeric();

But as soon as this row is executed:

GenericVector testResult = engine.Evaluate("t.test(group1, group2)").AsList();

There is a runtime error saying:

RDotNet.EvaluationException
{"Error: could not find function \"t.test\"\n"}

If I change the above call to

GenericVector testResult = engine.Evaluate("stats:::t.test(group1, group2)").AsList();

I get another that the stats.dll shared library cannot be loaded?!!

I currently have R for windows version 3.0.3 installed. Also tried with 3.1.0... Same result!

What is the issue here - am I doing something wrong? Quite unlikely since I just followed the example in the documentation.. ?

My machine is a brand new Win 7 64-bit.

Comments: Here is something interesting and odd! When creating a separate .NET FW 4.0 wrapper project for R.NET, referencing it from a .NET FW 4.5 web project and calling the code above, the abovementioned error persists. BUT, when referencing and calling the wrapper project from a .NET FW 4.0 Web project, everything works!! /Joakim

Viewing all articles
Browse latest Browse all 1634

Trending Articles