flycircuit_topn: NBLAST a single flycircuit neuron against database and return...

Description Usage Arguments Value Examples

Description

NBLAST a single flycircuit neuron against database and return scores

flycircuit_gmr_topn finds the top GMR Gal4 lines matching a FlyCircuit neuron query.

Usage

1
2
3
flycircuit_topn(query, n = 50, ...)

flycircuit_gmr_topn(query, n = 50)

Arguments

query

A flycircuit identifier

n

The number of scores to return (if n=0 or n is greater than the number of scores, then all scores are returned.

...

Additional arguments passed to flycircuit_nblast

Value

a data.frame in descending score order with columns

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
## Not run: 
## example of remote call via curl

## simple version collecting json results directly (RECOMMENDED)
curl http://vfbdev.inf.ed.ac.uk/ocpu/library/flynblastscores/R/flycircuit_topn/json \
  -d 'query="FruMARCM-M002262_seg001"'
# top 3 hits only
curl http://vfbdev.inf.ed.ac.uk/ocpu/library/flynblastscores/R/flycircuit_topn/json \
  -d 'query="FruMARCM-M002262_seg001"&n=3'

## more flexible version
curl http://vfbdev.inf.ed.ac.uk/ocpu/library/flynblastscores/R/flycircuit_topn \
  -d 'query="FruMARCM-M002262_seg001"'
# (return value looks like this and includes sesion key)
/ocpu/tmp/x05f62b2975/R/.val
/ocpu/tmp/x05f62b2975/messages
/ocpu/tmp/x05f62b2975/stdout
/ocpu/tmp/x05f62b2975/source
/ocpu/tmp/x05f62b2975/console
/ocpu/tmp/x05f62b2975/info
/ocpu/tmp/x05f62b2975/files/DESCRIPTION

# now collect results
curl http://vfbdev.inf.ed.ac.uk/ocpu/tmp/x05f62b2975/R/.val/json
curl http://vfbdev.inf.ed.ac.uk/ocpu/tmp/x05f62b2975/R/.val/csv

# specify number of hits, use "neuron" identifier
curl http://vfbdev.inf.ed.ac.uk/ocpu/library/flynblastscores/R/flycircuit_topn \
  -d 'query="fru-M-200266"&n=10'

## End(Not run)
# NBLAST a flycircuit neuron
qid="VGlut-F-100184"
res=flycircuit_gmr_topn(qid)
res

# return all results
resall=flycircuit_gmr_topn(qid, n=0)
nrow(resall)

# look at co-registered top hits on VFB
if(require('vfbr')){
 # find vfb ids for hits
 vfbids=vfbr::gmr_vfbid(res$id)
 # find vfb id for query
 qvfbid=vfb_tovfbids(qid)
 # stack browser URL for query neuron and top 10 hits
 u=vfb_stack_url(rev(c(qvfbid, vfbids[1:10])), clear = TRUE)
 ## Not run: 
 browseURL(u)
 
## End(Not run)
}

jefferis/flynblastscores documentation built on May 19, 2019, 2:50 a.m.