py_install | R Documentation |
Install Python packages into a virtual environment or Conda environment.
py_install(
packages,
envname = NULL,
method = c("auto", "virtualenv", "conda"),
conda = "auto",
python_version = NULL,
pip = FALSE,
...,
pip_ignore_installed = ignore_installed,
ignore_installed = FALSE
)
packages |
A vector of Python packages to install. |
envname |
The name, or full path, of the environment in which Python
packages are to be installed. When |
method |
Installation method. By default, "auto" automatically finds a method that will work in the local environment. Change the default to force a specific installation method. Note that the "virtualenv" method is not available on Windows. |
conda |
The path to a |
python_version |
The requested Python version. Ignored when attempting to install with a Python virtual environment. |
pip |
Boolean; use |
... |
Additional arguments passed to |
pip_ignore_installed , ignore_installed |
Boolean; whether pip should
ignore previously installed versions of the requested packages. Setting
this to |
On Linux and OS X the "virtualenv" method will be used by default ("conda" will be used if virtualenv isn't available). On Windows, the "conda" method is always used.
conda_install()
, for installing packages into conda environments.
virtualenv_install()
, for installing packages into virtual environments.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.