<p>type <code>conda info --envs</code>.  Look at your list of environments.  Say it's <code>base</code> that has <code>megahit</code> in it, do <code>conda activate base</code>, then just do <code>megahit</code>. </p>

CC BY-SA 4.0
2020-04-28T08:16:13.013Z
even in the ```base``` environment, the command ```megahit``` is not found.
RobH
CC BY-SA 4.0
2020-04-28T08:39:28.780Z
I re-installed ```megahit``` and now when I activate ```conda activate base```, ```megahit``` does work. Thank you!!
RobH
CC BY-SA 4.0
2020-04-28T06:41:31.707Z
2020-04-28T06:41:31.707Z
user3479780
<p>I want to use <code>MEGAHIT</code> (git: <a href="https://github.com/voutcn/megahit" rel="nofollow noreferrer">https://github.com/voutcn/megahit</a>) to assemble metagenome shotgun sequencing reads (illumina). </p>

<p>I install the package with the command <code>conda install -c bioconda megahit</code> as described in on the github page which yields: </p>

<pre><code>Solving environment: done

## Package Plan ##

  environment location: /home/datura-workstation/miniconda3

  added / updated specs:
    - megahit


The following NEW packages will be INSTALLED:

  megahit            bioconda/linux-64::megahit-1.2.9-h8b12597_0


Proceed ([y]/n)?
</code></pre>

<p>Where I click yes and the packages is installed. However, after installation I am not able to use the command <code>megahit</code> as this results in the error: <code>megahit: command not found</code>.</p>

<p>I use Ubuntu 18.04.3 LTS and have installed <code>miniconda3</code>.</p>

<p>I reproduced the installation of <code>megahit</code> on a windows computer with a virtual machine using the same Ubuntu version. On my virtual Ubuntu I CAN use the <code>megahit</code> command.</p>

<p>Could anyone please help me solve this problem? I searched the internet but cannot find a good solution on the issue (also not on the github issue page of this package).</p>

CC BY-SA 4.0
2020-04-27T13:26:16.683Z
Why not just install Anaconda3?
M__
CC BY-SA 4.0
2020-04-27T16:32:58.347Z
/home/datura-workstation/miniconda3/bin/megahit ? it should be there
StupidWolf
CC BY-SA 4.0
2020-04-28T05:35:57.423Z
Did you run `make install` after building?
Jose Fernando Lopez Fernandez
CC BY-SA 4.0
2020-04-28T07:41:28.440Z
@ATpoint Ah, gotcha. Thanks
Jose Fernando Lopez Fernandez
CC BY-SA 4.0
2020-04-28T08:23:21.463Z
In ```minconda3/bin``` there is no executable file named ```megahit```. (I checked the folder on my test virtual machine and there the file is indeed there.) That seems to be the problem. I can find the ```megahit``` on my workstation in the directory ```/home/datura-workstation/miniconda3/pkgs/megahit-1.2.9-h8b12597_0/bin```. Why is it there? Can I just copy these files to the ```miniconda/bin```?  All files of ```megahit``` are placed in this directory while they should be located in the ```miniconda3/bin``` directory.
RobH
CC BY-SA 4.0
2020-04-28T08:31:51.420Z
EDIT: I re-installed ```megahit``` and now there the ```megahit``` files are present in the ```miniconda3/bin```. However, I still receive the error.
RobH
CC BY-SA 4.0
2020-04-28T08:38:44.827Z
EDIT2: after activating ```conda activate base```, ```megahit``` became functional. Thanks all for the help!
RobH
<assembly>
"megahit: command not found" after correct installation with miniconda
# "megahit: command not found" after correct installation with miniconda

(Asked by: username_0 on 2020-04-27)

I want to use MEGAHIT (git: https://github.com/voutcn/megahit) to assemble metagenome shotgun sequencing reads (illumina). 
I install the package with the command conda install -c bioconda megahit as described in on the github page which yields: 
Solving environment: done

## Package Plan ##

  environment location: /home/datura-workstation/miniconda3

  added / updated specs:
    - megahit


The following NEW packages will be INSTALLED:

  megahit            bioconda/linux-64::megahit-1.2.9-h8b12597_0


Proceed ([y]/n)?

Where I click yes and the packages is installed. However, after installation I am not able to use the command megahit as this results in the error: megahit: command not found.
I use Ubuntu 18.04.3 LTS and have installed miniconda3.
I reproduced the installation of megahit on a windows computer with a virtual machine using the same Ubuntu version. On my virtual Ubuntu I CAN use the megahit command.
Could anyone please help me solve this problem? I searched the internet but cannot find a good solution on the issue (also not on the github issue page of this package).

**Tags:** assembly
> **Comments:**
> **username_1**: Why not just install Anaconda3?  
> **username_2**: /home/datura-workstation/miniconda3/bin/megahit ? it should be there  
> **username_3**: Did you run `make install` after building?  
> **username_3**: @ATpoint Ah, gotcha. Thanks  
> **username_0**: In ```minconda3/bin``` there is no executable file named ```megahit```. (I checked the folder on my test virtual machine and there the file is indeed there.) That seems to be the problem. I can find the ```megahit``` on my workstation in the directory ```/home/datura-workstation/miniconda3/pkgs/megahit-1.2.9-h8b12597_0/bin```. Why is it there? Can I just copy these files to the ```miniconda/bin```?  All files of ```megahit``` are placed in this directory while they should be located in the ```miniconda3/bin``` directory.  
> **username_0**: EDIT: I re-installed ```megahit``` and now there the ```megahit``` files are present in the ```miniconda3/bin```. However, I still receive the error.  
> **username_0**: EDIT2: after activating ```conda activate base```, ```megahit``` became functional. Thanks all for the help!  

---

## 1 answers

### Answer by username_4 on 2020-04-28. Score: 2 | Accepted answer

type `conda info --envs`. Look at your list of environments. Say it's `base` that has `megahit` in it, do `conda activate base`, then just do `megahit`.

> **Comments:**
> **username_0**: even in the ```base``` environment, the command ```megahit``` is not found.  
> **username_0**: I re-installed ```megahit``` and now when I activate ```conda activate base```, ```megahit``` does work. Thank you!!  

---

