Using MRO language with Anaconda

Microsoft R Open (MRO) is the enhanced distribution of R from Microsoft, a complete and free open source platform for statistical analysis and data science.

MRO was previously the default R interpreter in Anaconda. As of 2019 releases, Anaconda defaults to internal builds of R, henceforth the “Anaconda R ecosystem.” Learn more about how to use R with Anaconda.

Anaconda maintains an archive of MRO packages but will not update MRO packages. Support for MRO packages will be on a case-by-case basis.

If you are using MRO, it is recommended to migrate to R. Follow the migration directions below.

Migrate MRO conda environments to use Anaconda R

If you have an MRO-based conda environment and you want to shift over to Anaconda R to fix library errors or for updates, using conda will fail:

conda install r-base

Using conda will result in unsatisfiable errors because the MRO packages in your environment will conflict with Anaconda R counterparts. They’re not compatible and the metadata is designed to prevent this coexistence. You can create a new environment but that could require more effort depending on how many dependencies you have.

To resolve this, use the MRO-migrator tool. This tool removes all MRO-specific packages then updates the remaining packages to use Anaconda R instead of MRO. The remove-update cycle takes care of the unsatisfiability.

Warning

There’s minimal error handling in this tool. Back up your environments before running this tool.

To use the MRO-migrator tool, run its command line:

mro-migrator ~/miniconda3/envs/your-r-env

The default behavior lists which MRO-only packages will be removed. The tool does not change anything by default. To perform a migration, pass the --execute flag:

mro-migrator --execute ~/miniconda3/envs/your-r-env

MRO-supported operating systems

64-bit systems only for all operating systems - Windows, macOS, and Linux.

Windows 7.0 SP1, Windows 8.1, Windows 10, Windows Server 2008 R2 SP1, and Windows Server 2012.

Linux - CentOS, Red Hat Enterprise Linux, Debian, and Ubuntu.

When using MRO conda packages, starting the R interactive interpreter shows Microsoft R Open in the startup message. Anaconda Navigator, the Anaconda graphical package manager and application launcher, also creates R environments by default. You may instead select MRO when creating a new conda environment from within Navigator.

Microsoft R Client

Microsoft R Client is a free, community-supported data science tool for high-performance analytics built on top of MRO. Additionally, R Client introduces the powerful ScaleR technology and its proprietary functions to benefit from parallelization and remote computing.

Microsoft R Client is available as a conda package (r-mrclient). Users of Windows or RHEL-7/CentOS7/Ubuntu 14.04 and above also have the option to conda install the MicrosoftML R package for machine learning (r-mrclient-mml) and the pre-trained models for sentiment analysis and image detection (r-mrclient-mlm).

Creating a new environment with MRO instead of R

When creating a new environment, you can use MRO and not R by explicitly including mro-base in your list of packages.

With conda 4.6.4:

conda create -n mro-environment r-essentials mro-base
conda activate mro-environment

Switch an environment from R to MRO

Anaconda recommends using R as your default interpreter in Anaconda, however the directions below show you how to switch an environment from R to MRO.

Activate the environment containing R

If you use conda 4.4 or later, run:

conda install mro-base

If you use conda 4.3, run:

conda remove --force r-base  _r-mutex
conda install mro-base

The environment’s R interpreter will switch from R to MRO.


mro-basics: The MRO Basics metapackage contains everything in the Microsoft MRO installers. It does not include r-mrclient, r-mrclient-mml, or r-mrclient-mlm.

r-mrclient: Microsoft R Client is a free, community-supported, data science tool for high performance analytics.

r-mrclient-mml: MicrosoftML provides state-of-the-art fast, scalable machine learning algorithms and transforms for R. Depends on r-mrclient.

r-mrclient-mlm: MicrosoftML Machine Learning Models are pre-trained machine learning models for sentiment analysis and image detection. Depends on r-mrclient-mml.