The activation should be directly after virtualenv and seperate after conda.
Creating virtual environment
Install virtualenv if not already installed.
$ python -m pip install virtualenv
Create virtual environment. Replace [env_name] with a name of your choice.
$ mkdir [env_name]
$ virtualenv -p python3 [env_name]
or
$ python3 -m venv [env_name]
Activate created virtual environment.
For Windows:
$ [env_name]Scriptsactivate.bat
For Linux and Mac OS:
$ source [env_name]/bin/activate
Creating virtual environment using conda
Create virtual environment with conda. Replace [env_name] with a name of your choice.
$ conda create --name [env_name] python=3.6
To activate the environment (on Windows, MacOS and Unix),
$ conda activate [env_name]
The activation should be directly after virtualenv and seperate after conda.