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

New Post: protect(): protection stack overflow

$
0
0
1) Wrap it in a print() call, like this:
class Program
{
    static void Main( string[] args )
    {
        using (var engine = REngine.GetInstance())
        {
            engine.Evaluate("newcol <- c(1,2,3,4,5); print(newcol); print(Cstack_info())");
                            Console.ReadKey();
        }
    }
}
R.Net installs a console device that writes to Console.Out. Unfortunately, R does not autoprint when embedded, so you have to wrap things in a print call. I've submitted a PR for autoprint support in R.Net.

2) It could be how the data.frame is established. The protection stack size is currently set to 50000, which is close to the 30k items in your dataset. Again, its hard to tell without more code, even if that code just uses random data.

3) As long as you have C# objects that represent R variables, you are probably have items in the protection stack. Again, this is a very general statement and without specific code, its hard to tell.

Viewing all articles
Browse latest Browse all 1634

Trending Articles



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