How to create MIDACO (.dll) library for R in Windows

 

Step 1)

Install Rtools:

https://cran.r-project.org/bin/windows/Rtools/index.html

During installation, in "Select Additional Taks" tab, tick YES for:  Edit system PATH

 

Step 2)

Download   midacoR.f   source file and store it (e.g. Desktop)

 

Step 3)

Open Windows command prompt (CMD) and navigate to the folder where  midacoR.f  is stored

 

Step 4)

Set the CMD path, so that CMD console can access the "R" command.
For example, for version R-3.2.3 this command is as follows:

set path=%path%;C:\Program Files\R\R-3.2.3\bin

 

Step 5) 

Create the midacoR.dll file by typing following command in CMD console:

R CMD SHLIB midacoR.f

Now the midacoR.dll file should be created and placed in the same folder as midacoR.f

 


 

Screenshot of manual compilation

 

Need further help? Please contact us.