mojaveazure / angsd-wrapper

Utilities for analyzing next generation sequencing data
https://github.com/ANGSD-wrapper/angsd-wrapper
MIT License
17 stars 3 forks source link

install using 'angsd-wrapper shiny graphing' #47

Closed devonorourke closed 7 years ago

devonorourke commented 7 years ago

angsd-=_shiny_graphing_install_error.txt Hi everyone,

Loving all the detailed info provided with angsd-wrapper's Tutorial pages. However, I'm currently struggling with getting angsd-wrapper shiny graphing to work properly. For what it's worth, I've had no trouble running any of the commands (Genotype_likelihoods, SFS, etc.) using a cluster - my only issue at the moment is taking these data and getting Shiny to work with them.

The problem is that I can't get past the execution of the angsd-wrapper shiny graphing script. Here's a breakdown of what I've tried:

  1. Installed angsd-wrapper to my laptop home directory, following Tutorial instructions.

    • I can run angsd-wrapper successfully. The Usage menu appears upon entering "angsd-wrapper".
  2. Ran angsd-wrapper setup data to install all data on my laptop.

    • All data appears installed and accessible. Looks just like what I see installed on the cluster.
  3. Ran angsd-wrapper shiny graphing.

    • The output from that installation is attached as a .txt file to this message. The complication appears to be focused on a handful of R packages (that is, many packages appear to install without issue, but due to some packages failing to install I never see a new window pop up allowing me to load the files of interest into the Shiny app).

I tried running the same command from the cluster just to see what would happen and I don't get the same error message - things all appear to load properly without issue. Instead, it seems to stall, as I would imagine, when it's trying to open up a new Shiny window and can't (Listening on http://127.0.0.1:4915)... because it's a cluster and not my local machine?

This makes me think that I've done something fundamentally wrong with the install, or need to find a way to sync my existing R library on my laptop with the places that this Shiny app wants to put newly installed packages.

Thanks for any advice you can offer,

Devon

devonorourke commented 7 years ago

Hi all,

After a half day of more struggles, a few tears, and a lot of coffee, think I've identified the two roots of my problems...

First one is totally on me, and has to do with the R version I'm using. I had installed recently installed R version 3.4.0, but there was another R version lingering which I didn't account for: about a year ago I installed Jupyter Notebook and the R-essentials via Conda; that version was 3.2.2, which the "shinythemes" R package wasn't supporting, nor was "genomeIntervals". My first mistake I figured out was the $PATH to R from my terminal was to the //anaconda/bin/R variety (R v-3.2.2) instead of where I was testing the installation of packages for the shiny graphing ui.R and server.R scripts in R-studio (which was R v3.4.0).

Once I switched up the $PATH to look for R v3.4.0 first instead of //anaconda version, the Shiny app was able to launch.

The second problem which is tied to the first is that (I think) there are limitations in terms of which R packages you can install with the Conda R-essentials program. Not sure how many other folks will have Jupyter Notebook installed, but even the most current version of conda's R-essentials seems to not work properly when trying to install two of the R-packages for your ui.R script: genomeIntervals and Hmisc. I ended up manually installing those (from Bioconductor and CRAN respectively). Once that change was made, everything launched beautifully.

So for those folks it's critical that they specify to their 'core' R package wherever that might be (ex. /Library/Frameworks/R.framework/Resources).

Cheers,

Devon

arundurvasula commented 7 years ago

Great to hear! I'll close this issue now. Please let us know if you have any other issues!

rossibarra commented 7 years ago

Arun could you add a note of this potential issue when using Jupyter notebook to the wiki? Glad it worked out! On Tue, May 16, 2017 at 9:30 AM Arun Durvasula notifications@github.com wrote:

Great to hear! I'll close this issue now. Please let us know if you have any other issues!

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mojaveazure/angsd-wrapper/issues/47#issuecomment-301838223, or mute the thread https://github.com/notifications/unsubscribe-auth/ACeW4WOdfFh5VMkxxungT557Ixy5SJwsks5r6c8LgaJpZM4Nb3E4 .

--


Jeffrey Ross-Ibarra Dept. of Plant Sciences 262 Robbins Hall, Mail Stop 4 University of California One Shields Ave Davis, CA 95616

Tel: 530-752-1152 @jrossibarra www.rilab.org

devonorourke commented 7 years ago

One note: Because I'm working with a non-model organism with ~11,500 scaffolds (as opposed to something nice like 23 chromosomes...) when you upload the {name}_Thetas.graph.me to Shiny it's a super long list that's initially populated due to the unique call within the server.R script (line 109). Is there a way so that you can start by loading the file and insert the Scaffold of interest, rather than removing the 11,499 scaffolds you don't want, as a default? My current solution is to create a subsetted graph.me file with just the scaffold(s) I want, and that works fine, but thought it would be a feature to consider. Thanks!

arundurvasula commented 7 years ago

@rossibarra Yep, added to the FAQ.