View source: R/schemaObjects.R
getRows | R Documentation |
Retrive rows from a LabKey Server given a session and query object
getRows(session, query, maxRows=NULL, colNameOpt='fieldname', ...)
session |
the session key returned from getSession |
query |
an object representing a query on LabKey Server, a child object of the object returned by |
maxRows |
(optional) an integer specifying how many rows of data to return. If no value is specified, all rows are returned. |
colNameOpt |
(optional) controls the name source for the columns of the output dataframe, with valid values of 'caption', 'fieldname', and 'rname' |
... |
Any of the remaining options to |
This function works as a shortcut wrapper to labkey.selectRows
. All of the arguments are the same as documented in
labkey.selectRows.
See labkey.selectRows
for a discussion of the valid options and defaults for colNameOpt
. Note in particular
that with getRows the default is 'fieldname' instead of 'caption'.
A data frame containing the query results corresponding to the default view of the specified query.
Peter Hussey
getSession
, getSchema
, getLookups
, saveResults
labkey.selectRows
## Not run:
## simple example of getting data using schema objects
# library(Rlabkey)
s<-getSession(baseUrl="http://localhost:8080/labkey",
folderPath="/apisamples")
s # shows schemas
scobj <- getSchema(s, "lists")
scobj # shows available queries
scobj$AllTypes ## this is the query object
getRows(s, scobj$AllTypes)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.