A comprehensive database for glycans. The full GlycoBase dataset is stored in Synapse and can be downloaded here.
GlycoBase can be accessed online here.
-
Python 3
-
virtualenv (
pip install virtualenv
) -
R and RStudio
The synapser
R package developed by Sage Bionetworks depends on the older PythonEmbedInR
package, which has compatibility issues. For this reason, this app interacts with the Synapse API using the Synapse Python client and uses the R package reticulate
to call that Python code via the Shiny server.
Use the reticulate
package to create a Python 3 virtualenv and install the Python packages pandas
into it. In the R console:
> reticulate::virtualenv_create(envname = 'python35_env',
python = '/usr/bin/python3')
> reticulate::virtualenv_install('python35_env',
packages = c('synapseclient', 'requests', 'pandas'))
Note: We also include synapseclient
and requests
, which can be used to (optionally) require the user to log in using their Synapse credentials. This functionality it currently turned off. Additionally, avoid running library(reticulate)
as this will cause reticulate
to initialize in the R session with your system version of Python rather than the one specified in the python
arg of virtualenv_create()
. If this happens, you may see an error similar to:
ERROR: The requested version of Python ('~/.virtualenvs/python35_env/bin/python') cannot be used, as
another version of Python ('/usr/bin/python') has already been initialized.
If you see this error, restart your R session and run the two commands above to create your virtual environment.
In RStudio, open app.py
and click the "Run App" button or run shiny::runApp()
in the console. Open a web browser and go to http://127.0.0.1:7450
to see the app.
Sensitive data like passwords and secret keys should never be checked into git in cleartext (unencrypted). If you need to store sensitive info, you can use the openssl cli to encrypt and decrypt the file.
$ openssl enc -aes256 -base64 -in .Renviron -out .Renviron.encrypted
$ openssl enc -d -aes256 -base64 -in .Renviron.encrypted -out .Renviron
- See the full Synapse REST API docs for detailed explanations of all available endpoints.