Skip to contents

crant_voxdims returns the image voxel dimensions which are normally used to scale between raw and nm coordinates.

Usage

crant_voxdims(url = choose_crant(set = FALSE)[["fafbseg.sampleurl"]])

crant_nm2raw(x, vd = crant_voxdims())

crant_raw2nm(x, vd = crant_voxdims())

Arguments

url

Optional neuroglancer URL containing voxel size. Defaults to getOption("fafbseg.sampleurl") as set by choose_crant.

x

3D coordinates in any form compatible with xyzmatrix

vd

The voxel dimensions in nm. Expert use only. Normally found automatically.

Value

For crant_voxdims A 3-vector

for crant_raw2nm and crant_nm2raw an Nx3 matrix of coordinates

Details

relies on nat >= 1.10.4

Examples

crant_voxdims()
#> Error : Unable to find chunked graph credentials!
#> Please set by doing:
#>   flywire_set_token()/fanc_set_token() etc 
#> For further details see:
#> https://github.com/seung-lab/cloud-volume#chunkedgraph-secretjson
#> Error in crant_scene(): It looks like you do not have a stored token. Please use `flywire_set_token()` to make one.Note you may have to do this in addition to `crantr_set_token()`
crant_raw2nm(c(37306, 31317, 1405))
#> Error : Unable to find chunked graph credentials!
#> Please set by doing:
#>   flywire_set_token()/fanc_set_token() etc 
#> For further details see:
#> https://github.com/seung-lab/cloud-volume#chunkedgraph-secretjson
#> Error in crant_scene(): It looks like you do not have a stored token. Please use `flywire_set_token()` to make one.Note you may have to do this in addition to `crantr_set_token()`
crant_raw2nm('37306 31317 1405')
#> Error : Unable to find chunked graph credentials!
#> Please set by doing:
#>   flywire_set_token()/fanc_set_token() etc 
#> For further details see:
#> https://github.com/seung-lab/cloud-volume#chunkedgraph-secretjson
#> Error in crant_scene(): It looks like you do not have a stored token. Please use `flywire_set_token()` to make one.Note you may have to do this in addition to `crantr_set_token()`
if (FALSE) { # \dontrun{
crant_nm2raw(clipr::read_clip())
} # }