Skip to content

Commit

Permalink
Merge pull request #59 from compbiocore/develop
Browse files Browse the repository at this point in the history
New feature and bug fixes
  • Loading branch information
fernandogelin authored Jul 8, 2019
2 parents cffec2b + dcf8b27 commit de436ed
Show file tree
Hide file tree
Showing 12 changed files with 627 additions and 130 deletions.
63 changes: 60 additions & 3 deletions docs/src/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Download [Julia]("https://julialang.org/downloads/")

### Supported Operating Systems:

#### macOS
#### macOS

Sierra, High Sierra, and Mojave.

Expand All @@ -32,9 +32,67 @@ Windows 10, Windows 7.
2. Download the [VIVA Jupyter Notebook](https://github.com/compbiocore/VariantVisualization.jl/blob/master/VIVA.ipynb).
3. Follow the in-notebook instructions to generate your plots.

------

## Using Docker and Docker Compose

If you don't want to install Julia and VariantVisualization, you can use the Docker images provided.
For that, first [install Docker](https://docs.docker.com/install/).

#### Using Docker

We provide two images, one with a Jupyter Notebook and one with a command line script for VIVA.

Create a project folder and navigate to it:
```shell
mkdir project_x
cd project_x
```

Make sure to add your project VCF files to that folder. That directory will be mapped to `/notebook/data` inside of the container.

Then, to run the Jupyter Notebook, from the terminal or Windows PowerShell:
```shell
docker run --rm -p 8888:8888 -e JUPYTER_ENABLE_LAB=yes -v "$PWD":/notebook/data compbiocore/viva-notebook
```
Go to `http://0.0.0.0:8888/?token=<enter token here>`

[Click here](https://jupyter-docker-stacks.readthedocs.io/en/latest/index.html) for more information about Jupyter Docker Images.

To run VIVA Command Line Tool:

On Mac or Linux:
```shell
docker run -it --rm -v "$PWD":/data compbiocore/viva-cli arg1 arg2 arg3
```

On Windows:
```shell
docker run -it --rm -v "${pwd}":/data compbiocore/viva-cli arg1 arg2 arg3
```

#### Using Docker Compose

To run the images with Docker Compose, copy the [`docker-compose.yml`](https://github.com/compbiocore/viva-docker/blob/master/docker-compose.yml) file to a local directory. From that same directory, run the commandas below.

!!! Note
Your current directory will mount to `/notebook/data` in the notebook image and to `/data` in the CLI image.

- Notebook
```shell
docker-compose up viva-notebook
```

- Command Line Tool
```shell
docker-compose run viva -f /data/file.vcf arg2 arg3 ...
```

-----

### Latest Features

To stay up to date with cutting edge development features install VariantVisualization.jl from the Master branch.
To stay up to date with cutting edge development features install VariantVisualization.jl from the Master branch.

Using git from the command line:

Expand All @@ -58,4 +116,3 @@ Developers may contribute to these open source tools by using [functions contain
We have included in-line comments within the code for the [VIVA command line tool](https://github.com/compbiocore/VariantVisualization.jl/tree/master/viva).

The ***VIVA Jupyter notebook*** is powered by a [main function](https://github.com/compbiocore/VariantVisualization.jl/tree/master/src/new_notebook_utils.jl) which takes arguments defined by the user in the notebook. We welcome users to post in issues to request a new feature or bug fix.

Binary file added output/Genotype_test_4X_191.vcf.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added output/Read_Depth_test_4X_191.vcf.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 8 additions & 19 deletions src/VariantVisualization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,18 @@ using ArgParse
using DelimitedFiles
using Test

#using Base.Filesystem

#include("vcf_utils.jl")
#include("plot_utils.jl")

#end #module

export
test_parse_main,
format_reader,
load_vcf,
clean_column1!,
genotype_cell_searcher_maf_correction,
genotype_cell_searcher,
dp_cell_searcher,
load_siglist,
sig_list_vcf_filter,
genomic_range_vcf_filter,
load_sort_phenotype_matrix,
reorder_columns,
#sig_list_vcf_filter,
#genomic_range_vcf_filter,
#load_sort_phenotype_matrix,
#reorder_columns,
select_columns,
genotype_heatmap2,
#genotype_heatmap2,
dp_heatmap2,
avg_sample_dp_scatter,
avg_variant_dp_line_chart,
Expand Down Expand Up @@ -72,14 +63,12 @@ export
add_pheno_matrix_to_dp_data_for_plotting,
generate_hover_text_array,
generate_hover_text_array_grouped,
save_graphic
save_graphic,
build_set_from_list

#include("vcf_utils.jl")
include("vcf_utils_complete.jl")
include("plot_utils.jl")
include("new_notebook_utils.jl")
include("init.jl")
#include("v1_VIVA_notebook_utils.jl")
#include("io_filters.jl")

end # module
Loading

0 comments on commit de436ed

Please sign in to comment.