Skip to content
Vinh Tran edited this page Jun 9, 2023 · 1 revision

Table of Contents

Introduction

fas.setup is used to prepare the annotation tools and databases that are used by default by FAS.

Currently, FAS uses 7 standard databases/annotation tools: PFAM, SMART, fLPS, SEG, COILS, THMHH 2.0c and SignalP 4.1g.

NOTE: we provide compiled code only for PFAM, COILS and SEG. fLPS will be automatically downloaded and installed. For SMART, you need to download it from EMBLEM and give the path to fas.setup. For TMHMM and SignalP, you can decide if you want to include those two tools to the annotation step (recommended) or ignore them. For using TMHMM version 2.0c and SignalP version 4.1g, you need to request a license from the authors at https://services.healthtech.dtu.dk, and save the downloaded files in the same directory. FAS will do the rest for you ;-)

NOTE2: SignalP 5.0b is not supported yet!!!

Usage

I use ~/annotation_tools as the directory for the installed annotation tools throughout this manual. You can change it according to your need!

Newly install annotation tools

fas.setup -t ~/annotation_tools

Inside the output directory ~/annotation_tools you will find a file called annoTools.txt that contains all installed annotation tools. If you wish to discard any of them from the annotation process, you can just remove the unneeded tools from that file.

If the function successfully finished and all the installed tools are runable, you will see #checked at the last line of annoTools.txt. In case any of the tools cannot be run and you want to exclude them from the annotation pipeline, you can remove the corresponding line(s) from the annoTools.txt file and run the function again to check the rest:

fas.setup -t ~/annotation_tools --checkExecutable

Without the #checked line in the annoTools.txt file, other FAS functions (like fas.doAnno and fas.run) cannot be run.

Reinstall annotation tools

In some cases you will need to reinstall or update the annotation tools. If you want to do that for all the tools, just use the command

fas.setup -t ~/annotation_tools --force

Or you can reinstall only some particular tools with the command

fas.setup -t ~/annotation_tools --reinstall SEG PFAM

Please note, in this case, the file annoTools.txt will be also rewritten. If you've modified it before, you need to do that again.

Write path configuration file

After fas.setup has successfully run, the path to the annotation tools (~/annotation_fas in this case) will be saved in a configuration file for FAS (path/to/python3/libraries/greedyFAS/pathconfig.txt). Without this file, annoFAS will not be executable.

If you need to re-create this path configuration file, e.g. after re-installing FAS, using the old annotation tools, you can run setupFAS with --savePath option

fas.setup -t ~/annotation_tools --savePath

Check if FAS ready to run

fas.setup -t ./ --check

Here the input for -t can be any path. This command will tell you if any errors occur with the annotation tools, or if pathconfig.txt file does not exist. If everything are fine and FAS is ready to run, you will get a confirm message together with the path to installed annotation tools, such as:

vinh@vinh-desktop:~/bionf/FAS$ fas.setup -t ./ --check
Annotation tools can be found at /home/vinh/annotation_fas. FAS is ready to run!

For testing the annotation tools on a fasta file, you can run this command:

fas.doAnno -i test_annofas.fa -o test_output

test_annofas.fa is a demo multiple fasta file, which is saved in the installed greedyFAS directory. Use any json viewer (such as https://jsoneditoronline.org) to inspect the output file test_output/test_annofas.json. If you can see all tools/databases annotated for those demo sequences then everything was set correctly and you are ready to use greedyFAS.

Add COILSDIR to bashrc or bash_profile

Everytime your restart the terminal you need to run source ~/annotation_tools/fas.profile to set value for COILSDIR variable of COILS program. If you want to set it permanently, you can add the following line in your ~/annotation_tools/fas.profile file to ~/.bashrc (or `~/.bash_profile or ~/.zshrc, depends on your system)

export COILSDIR=/home/vinh/annotation_fas/COILS2/coils

By that, everytime when you start the terminal, the value for COILSDIR will be set automatically.