Skip to main content
deleted 17 characters in body
Source Link
korakot
  • 41.3k
  • 21
  • 132
  • 150

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
import rpy2
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentation

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
import rpy2
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentation

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentation

Fixed link for the documentation.
Source Link
lgautier
  • 11.6k
  • 31
  • 43

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
import rpy2
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentationrpy2 documentation

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
import rpy2
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentation

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
import rpy2
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentation

Source Link
korakot
  • 41.3k
  • 21
  • 132
  • 150

In case you want to use Python and R together, you can use R magic for some cells.

# activate R magic
import rpy2
%load_ext rpy2.ipython

Then, whenever you want to use R, you begin the cell with %%R

%%R
x <- 42
print(x)

More details in rpy2 documentation