mmc46 / neuprintr

R client utilities for interacting with the neuPrint connectome analysis service

Home Page:https://natverse.github.io/neuprintr

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

natverse Travis-CI Build Status Docs

neuprintr

The goal of neuprintr is to provide R client utilities for interacting with the neuPrint connectome analysis service. neuPrint is set of tools for loading and analysing connectome data into a Neo4j database. You can find neuprint on Github. There is also a great python client available from Philipp Schlegel, neuprint-python if that’s your thing. neuPrint is currently being used for connectome analysis in aid of neuronal reconstruction efforts at Janelia Research Campus. Using this R package in concert with the nat ecosystem developed primarily by Greg Jefferis is highly recommended. Hor more information, have a look here.

Installation

# install
if (!require("devtools")) install.packages("devtools")
devtools::install_github("natverse/neuprintr")

# use 
library(neuprintr)

Authentication

In order to use neuprintr you will need to be able to login to a neuPrint server and be able to access it underlying Neo4j database. Currently this means you have to be on the network, SECURE WiFi or have a VPN for the Janelia network, and have an authorised account.

access your bearer token

To make life easier, you can then edit your R.environ file to contain information about the neuPrint server you want to speak with, your token and the dataset hosted by that server, that you want to read. For detailed instructions use:

?neuprint_login

To get started quickly, all you need to do is

conn = neuprint_login(server= "https://emdata1.int.janelia.org:11000",
   token= "asBatEsiOIJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6ImIsImxldmVsIjoicmVhZHdyaXRlIiwiaW1hZ2UtdXJsIjoiaHR0cHM7Ly9saDQuZ29vZ2xldXNlcmNvbnRlbnQuY29tLy1QeFVrTFZtbHdmcy9BQUFBQUFBQUFBDD9BQUFBQUFBQUFBQS9BQ0hpM3JleFZMeEI4Nl9FT1asb0dyMnV0QjJBcFJSZlI6MTczMjc1MjU2HH0.jhh1nMDBPl5A1HYKcszXM518NZeAhZG9jKy3hzVOWEU")
# nb this token is a dummy

Example

Now we can have a look at what is available

# What data sets are available?
neuprint_datasets()

# What's the underlying database
neuprint_database()

# What are the regions of interrst in your default datasest (specified in R.environ, see ?neuprint_login)
neuprint_ROIs()

Use the client to request data from neuprint. The method will run an arbitrary cypher query against the database. For information about the neuprint data model, see the neuprint explorer web help: https://emdata1.int.janelia.org:11000/help.

Some cyphers and other API endpoints have been explored by this package. Have a look a the functions, for example, that give you neuron skeletons, synapse locations, connectivity matrices, etc.

?neuprint_get_adjacency_matrix
?neuprint_ROI_connectivity
?neuprint_get_synapses
?neuprint_read_neurons

Example data

Acknowledging the data and tools

Neuprint comprises a set of tools for loading and analyzing connectome data into a Neo4j database. Analyze and explore connectome data stored in Neo4j using the neuPrint ecosystem: neuPrintHTTP, neuPrintExplorer, Python API.

This package was created by Alexander Shakeel Bates and Gregory Jefferis. You can cite this package as:

citation(package = "neuprintr")

Bates AS, Jefferis GSXE (2019). neuprintr: R client utilities for interacting with the neuPrint connectome analysis service. R package version 0.1.0. https://github.com/natverse/neuprintr

About

R client utilities for interacting with the neuPrint connectome analysis service

https://natverse.github.io/neuprintr


Languages

Language:R 100.0%