Installation of LEfSe

Introduction

LEfSe (Linear discriminant analysis Effect Size)는 통계 분석을 통해 특정 class와 관련있는 feature를 찾는 방법이다. Conda를 이용해 간단하게 설치할 수 있어야 하나, library version 차이로 인해 설치가 원활히 되지 않는 경우가 발생한다. 여기서는

lefse

Installation (conda)

아래 명령어 실행을 통해 LEfSe를 설치한다. 다만, 아래 설치는 매우 제한적인 시스템에서 테스트한 결과로, 일부 시스템에서는 정상적으로 설치되지 않을 수도 있다.

conda create -n lefse python=2.7
conda activate lefse
conda install bioconda::lefse -y

wget --no-check-certificate https://bdsl.jbnu.ac.kr/blog/wp-content/uploads/2023/09/environment.yml
conda env create -f environment.yml

(Optional) 기존 환경 삭제하기

lefse 환경이 존재하는 경우, 아래 명령을 통해 환경을 삭제한다.

conda env remove -n lefse

사용 테스트

SegataLab의 GitHub example code를 이용해 정상 설치 여부를 확인한다.

https://github.com/SegataLab/lefse/blob/master/example/bioconda-lefse_run.sh

conda activate lefse
wget https://github.com/biobakery/biobakery/raw/master/test_suite/biobakery_tests/data/lefse/input/hmp_small_aerobiosis.txt -O hmp_aerobiosis_small.txt
lefse_format_input.py hmp_aerobiosis_small.txt hmp_aerobiosis_small.in -c 1 -s 2 -u 3 -o 1000000
lefse_run.py hmp_aerobiosis_small.in hmp_aerobiosis_small.res
lefse_plot_res.py hmp_aerobiosis_small.res hmp_aerobiosis_small.png
lefse_plot_cladogram.py hmp_aerobiosis_small.res hmp_aerobiosis_small.cladogram.png --format png
mkdir biomarkers_raw_images
lefse_plot_features.py hmp_aerobiosis_small.in hmp_aerobiosis_small.res biomarkers_raw_images/

##

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top