Project

Project

Projects in Synapse are “containers” that group relevant content and people together. All data must be uploaded into a project. Projects can be private so only you can see the contents, they can be shared with your collaborators, or they can be made public so anyone on the web can view your research.

Tutorial purpose

In this vignette you will:

  1. Create a new project
  2. Print stored attributes about your project
  3. Get an existing project

Prerequisites

  1. Make sure that you have completed the Installation setup.
  2. Make sure that you have completed the Authentication setup.

1. Create a new project

library(synapser)
synLogin()

# Project names must be globally unique
project_name <- paste0(
  "My uniquely named project about Alzheimer's Disease ",
  paste(sample(c(letters, LETTERS, 0:9), 8, replace = TRUE), collapse = "")
)
project <- Project(name = project_name) |> synStore()
cat("Created project:", project$id, "\n")

Now that you have created your project you are able to inspect the project in the Synapse web UI.

3. Get an existing project

Each Project only needs to be created once. Since you’ve already created it you can access it again by retrieving it using its name.

my_project_object <- Project(name = project_name) |> synGet()
cat("I just got my project:", my_project_object$name, ", id:", my_project_object$id, "\n")
The result will look like:
I just got my project: My uniquely named project about Alzheimer's Disease, id: syn12345678

Clean Up

Delete the project and all its contents when done:

synDelete(project)

References used in this tutorial