knitr::opts_chunk$set(echo = TRUE)
rh5pydclient
is a R wrapper for the python package h5pyd
.
library(rh5pydclient)
Initialize python and check for required packages.
initPython()
This server is an AWS instance with ID i-046c975236be75444
. It is not usually running. To run
this vignette, email Sam and ask to have it started.
Connect to a h5serv
or hsds
server and identify a H5 file to open.
endpoint = 'http://54.224.146.67:5000' domain = 'tinyfile.public.gliobulk.org' conn <- initConn(domain=domain, mode='r+', endpoint=endpoint)
Obtain a handle to a dataset.
D <- getDataset(conn, 'tinyds')
At present, the only way to signify the submatrix to fetch or store to is to pass slices as constant
R strings in the format start:stop:step
. The indices should be in R convention, i.e.,
the first array subscript is 1 (not 0) and if stop-start
is a multiple of step
,
the index stop
is included in the slice.
A <- array(c(4, 14, 7, 17, 5, 15, 9, 19), dim=c(2, 2, 2)) setSubmatrix(D, c('7:8:1', '11:12:1', '11:12:1'), A) # check getSubmatrix(D, c('7:8:1', '11:12:1', '11:12:1'))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.