diff --git a/README.md b/README.md index 2e7ab6f67..366da9ad9 100644 --- a/README.md +++ b/README.md @@ -28,9 +28,9 @@ $ mvn clean package -DskipTests ## Running mango mango is packaged via [appassembler](http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/) and includes all necessary dependencies. -Running an example script: +Running an example script locally: ``` -From the main folder of mango, run ./example-files/run-example.sh to see a demonstration of chromosome 17, region 7500000-7515000. +From the main folder of mango, run ./example-files/run-local.sh to see a demonstration of chromosome 17, region 7500000-7515000. ``` For help launching the script, run `bin/mango-submit -h` ```` @@ -63,4 +63,10 @@ Using SPARK_SUBMIT=/Applications/spark-1.6.1-bin-hadoop2.4/bin/spark-submit View the visualization at: 8080 Quit at: /quit ``` + +Running an example script on hdfs: +``` +From the main folder of mango, run ./example-files/run-hdfs.sh to see a demonstration of chromosome 17, region 7500000-7515000. +``` + Note that for logging, you must use the /quit url for the log to be produced. diff --git a/example-files/run-hdfs.sh b/example-files/run-hdfs.sh new file mode 100755 index 000000000..84791d748 --- /dev/null +++ b/example-files/run-hdfs.sh @@ -0,0 +1,11 @@ +# get current local directory +DIR=$( cd $( dirname ${BASH_SOURCE[0]} ) && pwd ) +hdfs dfs -put ${DIR} + +bin/mango-submit ${DIR}/hg19.17.2bit \ +-genes http://www.biodalliance.org/datasets/ensGene.bb \ +-reads example-files/chr17.7500000-7515000.bam.adam \ +-variants example-files/ALL.chr17.7500000-7515000.phase3_shapeit2_mvncall_integrated_v5a.20130502.genotypes.vcf \ +-show_genotypes \ +-discover \ +-port 8080 diff --git a/example-files/run-example.sh b/example-files/run-local.sh similarity index 52% rename from example-files/run-example.sh rename to example-files/run-local.sh index a6640fc6f..c1c68bc70 100755 --- a/example-files/run-example.sh +++ b/example-files/run-local.sh @@ -1,7 +1,12 @@ -bin/mango-submit ./example-files/hg19.17.2bit \ +# get current local directory +DIR=$( cd $( dirname ${BASH_SOURCE[0]} ) && pwd ) + +# reference 2 bit does not need 'file:' because it is only read from the master +bin/mango-submit ${DIR}/hg19.17.2bit \ -genes http://www.biodalliance.org/datasets/ensGene.bb \ -reads ./example-files/chr17.7500000-7515000.sam.adam \ -variants ./example-files/ALL.chr17.7500000-7515000.phase3_shapeit2_mvncall_integrated_v5a.20130502.genotypes.vcf \ -show_genotypes \ --discover +-discover \ +-port 8080