A View view is a type of Synapse Tabletable. Views display rows and columns of information, and they can be shared and queried just like a Tabletable. Unlike Tablestables, Views views do not store data. Instead, Views views are essentially queries of other data already in Synapse. They allow you to see Filesgroups of files, Tablestables, Projectsprojects, or Submissions submissions and any associated metadata about those objects items at a glance. You can define the scope of a View view to include the items that you want to group together.
You can use a View view to:
Search and query many Projectsprojects, Files files, Submissions submissions, and Tables and tables at once
View and edit File file or Table table metadata in bulk
Group or link Fileslink files, Tables tables, Projectprojects, or Submissions submissions together by their annotations
You can create a View that contains Files, Tables, Projects, or Submissions. A File View lists all Files or Tables within one or more Folders or Projects. A Project View lists all Projects you’ve added to the view. A Submission View lists all Submissions within one or multiple Evaluation Queues.
Creating Views
You can create Views views from the web client to organize and group content within Synapse. Instructions for creating Views views using the programmatic clients can be found in the Python docs and in the R docs.
Create a
...
file view
A file view lists all files or tables within one or more folders or projects. To create a File View, select the Project file view, navigate to the project where you would like to create the Viewview. The Project project you choose does not have to contain the items you are including in your Viewfile view. Navigate to into the Tables tab and select Add File View in the Tables Tools menu. You will select the files of interest by defining the scope, which is the Projectproject(s) and Folders folders that contain your files. File Views views can also contain Tables tables or Foldersfolders; you can choose which kinds of items you would like to include during this the setup process. The scope of a File View file view can have a maximum of 20,000 folders or sub-folders.
Create a
...
project view
A project view lists all projects you’ve added to the view. To create a Project Viewproject view, select the Project project in which you would like to create the view. You will select the projects of interest by defining the scope as above for file views. The only notable difference between creating a Project View project view and a File View file view is that for project views, there is a 1:1 relationship between the projects you select in your scope and the projects that are shown in the view. The scope of a Project View project view can have a maximum of 20,000 Projectsprojects.
Create a
...
submission view
A submission view lists all submissions within one or multiple evaluation queues. To create a Submission View, select the Project in which submission view, navigate to the project where you would like to create the view. The Project project you choose does not have to contain the submissions or the evaluation queues that are included in the view. Navigate to the Tables tab and select Add Submission View in the Tables Tools menu. The submissions that are included in the View view are defined by its scope, which is the list of Evaluation Queues evaluation queues containing the submissions. For more information, read about how to use Submission Views with Evaluation Queuessubmission views with /wiki/spaces/DOCS/pages/1985151345. The scope of a View submission view can have a maximum of 20,000 evaluation queues.
Updating the
...
scope or
...
content of a
...
view
Views can be edited to change the scope or what types of content are displayed. Navigate to the View view and then select Show Scope of View in the Tools menu. Click Edit Scope to view and change your View view preferences. Once you click Save, Synapse may take a few moments to rebuild the updated Viewview.
Query a
...
view
A view can be queried like any other Table in Synapse. See Search Tables tables and Viewsviews for more information.
Insert a
...
view into a
...
wiki
Views can also be embedded in a Wikiwiki. You can embed the entire View view or a subset of it.
Navigate to a Wiki wiki and click the Wiki Tools menu. Select Edit Project Wiki. In the Wiki wiki editing window, select the Insert tab and then Table: Query on a Synapse Table/View. To embed the entire View view into the Wiki wiki enter SELECT * FROM syn12345678
in the resulting pop-up window, replacing syn12345678
with the synID for your view.
To embed a subset of the File View, like the advanced search query in the previous example, a view, enter SELECT * FROM syn12345678 WHERE Cell_Type = ‘PSC’
.
...
Save the query to embed the view.
Update
...
annotations in
...
bulk
Views can be used to update annotations for many Files files or Tables tables at once. To add new annotations, see the Annotations article. To update other metadata in bulk, such as Provenance, see the Bulk Processing article.
For example, if you would like to use the Python client to update the annotation “dogSays:bark” to “dogSays:woof” in for every file in a File View file view with the synID syn12345678
, you can use:
Code Block | ||
---|---|---|
| ||
from synapseclient import Table foo = syn.tableQuery('select * from syn456') bar = foo.asDataFrame() # add in annotation as a column bar['dogSays'] = 'woof' # store the fileview with the new annotation in Synapse fv = syn.store(synapseclient.Table(foo.tableId, bar)) |
Versioning a
...
view
You can create a version history for any View view in Synapse. Versioning helps you keep a record of what changes you made to the View view and when you made them. For more information on versioning a Viewview, see the Versioning Tables tables and Viewsviews page.
See Also
Annotations and Queriesqueries, Tables, Wikis
Include Page | ||||
---|---|---|---|---|
|