none
How to call R from .NET to save the result for using it programmatically at later point of time RRS feed

  • Question

  • I am a .NET developer and new to R. we have an existing R script that generates annova decision tree in pdf format based on some input from excel. For a given criteria, people are manually parsing the tree and getting the node value and using it for their purposes. we need to automate the process now. I have two requirements
    1. First, I need to make a call to R exe or library from .net program. 
    2. The tree result of above call should be stored in database or filesystem, which needs to be retrived programmatically later point of time for use. 
    3. At a later point of time, the above tree result needs to be loaded and parse the tree programmatically for the given criteria and get the node value. 

    I installed Microsoft R open and R studio, VSTS tools for R. Please let me know the tools/library and approach to achieve above requirement. 
    Wednesday, June 8, 2016 8:39 PM

All replies

  • Hello,

    The requirement you just mentioned can be achieved with the simple architecture by using R and .Net. As you mentioned in your requirements, this is how I would have approached for this solution.

    • Set up a Deploy R open server which can host my R code and expose them as web-service.
    • Than create a web application (or any application which you like as far as the user is accessing it), Upload your file to the Deploy-R server.
    • Your R code accepts the input, calculate the annova tree and stores the result into the database.
    • User can now enter his inputs to retrieve the values from the database. 
    • You can also program the tree parsing using .net and display to the user at the same time.

    You might need to invest time on how the whole application will communicate with each other.

    Regards,

    Anish

    • Proposed as answer by CarlNan Tuesday, December 13, 2016 8:21 AM
    Tuesday, June 14, 2016 10:17 AM