This repostiory contains a fast implementation of the AlphaBeta algorithm first proposed by Yadollah Shahryary, Frank Johannes and Rashmi Hazarika. The original R implemtation is accessible on Github here. I matched the original parameters needed for the program, to the old documentation is still useful.
Additionally, this repository also contains a program for creating metaprofiles of (epi)genetic data. They are connected, so output from the metaprofile program can automcatically be fed into AlphaBeta.
The program depends on OpenBLAS for fast matrix calculations. On Linux, you can install them with your package manager, on MacOS you can use Homebrew. On Windows, you can download prebuilt binaries from the OpenBLAS website.
Original Installation instructions here.
Debian/Ubuntu:
bash
sudo apt update
sudo apt install libopenblas-dev
If you don't have sudo rights, ask your system administrator.
MacOS:
bash
brew install openblas
Windows:
Download the prebuilt binaries from the OpenBLAS website (Big .zip button). For building from source, see this.
If you are somewhat familiar with coding and git, I'd recommend this approach: You'll need to install Rust and git first. Then, you can clone this repository and build the program yourself:
bash
git clone https://github.com/constantingoeldel/alphabeta-rs.git
cd alphabeta-rs
cargo install --path .
This will install the programs on your system. You can then ensure everything works by running:
```bash alphabeta --help
metaprofile --help ```
If you received an error message about libopenblas, you will need to run the code with cargo (I don't really understand this issue)
```bash cargo run --release --bin alphabeta
cargo run --release --bin metaprofile ```
If you want to use a new version of the program, either download the new binaries from the same source or run:
bash
cd alphabeta-rs
git pull
cargo install --path .
```bash
Usage: alphabeta [OPTIONS] --edges
Options:
-i, --iterations
```bash
Usage: metaprofile [OPTIONS] --methylome
Options:
-m, --methylome
About window step and size:
Size determines the "length" of each window, for example for --window-size 5
, each window will span 5% of the length of the gene it is in. If you supply --absolute
, the size will be interpreted as the number of basepairs instead of a percentage, so 5 bp.
Step determines the distance between the start of each window. If you supply --window-step 1 and --window-size 5
, the first window will go from 0% to 5% and the second from 1% to 6% and so on. If you supply --window-step 5 and --window-size 5
, the first window will go from 0% to 5% and the second from 5% to 10% and so on. In the latter case, you can also omit the step
paramter, as it will default to the same value as size
.
bash
alphabeta \
--edges ./data/edgelist.txt \
--nodes ./data/nodelist.txt \
--output ./data/output
bash
metaprofile \
--methylome ../methylome/within_gbM_genes/ \
--genome ../methylome/gbM_gene_anotation_extract_Arabidopsis.bed \
--output-dir /mnt/extStorage/workingDir/./windows/wt \
--edges ../methylome/edgelist.txt \
--nodes ../methylome/nodelist.txt \
--alphabeta \
--name wildtype \
--window-step 1 --window-size 5