Skip to contents

Class representing a local Seurat object in a Vitessce dataset.

Usage

Details

Seurat object wrapper class

Super class

vitessce::AbstractWrapper -> SeuratWrapper

Public fields

obj

The object to wrap.

assay

The assay name in the Seurat object.

cell_set_meta_names

The keys in the Seurat object's meta.data to use for creating cell sets.

cell_set_meta_name_mappings

The keys in the Seurat object's meta.data to use for cell set names mapped to new names.

cell_set_meta_score_mappings

The keys in the Seurat object's meta.data to use for cell set names mapped to keys for scores.

num_genes

Number of genes to use for the heatmap.

Methods

Inherited methods


Method new()

Create a wrapper around a Seurat object.

Usage

SeuratWrapper$new(
  obj,
  assay = "RNA",
  cell_set_meta_names = NA,
  cell_set_meta_score_mappings = NA,
  cell_set_meta_name_mappings = NA,
  num_genes = 10,
  ...
)

Arguments

obj

The object to wrap.

assay

The assay name under the assays part of the Seurat object.

cell_set_meta_names

An optional list of keys in the object's meta.data list to use for creating cell sets.

cell_set_meta_score_mappings

If cell_set_meta_names is provided, this list can also be provided to map between meta.data keys for set annotations and keys for annotation scores.

cell_set_meta_name_mappings

If cell_set_meta_names is provided, this list can also be provided to map between meta.data keys and new names to replace the keys in the interface.

num_genes

The number of genes to include in the expression matrix. Note: this parameter is temporary and should be changed to something more useful such as number of most variable genes.

...

Parameters inherited from AbstractWrapper.

Returns

A new SeuratWrapper object.


Method convert_and_save()

Create the JSON output files, web server routes, and file definition creators.

Usage

SeuratWrapper$convert_and_save(dataset_uid, obj_i)

Arguments

dataset_uid

The ID for this dataset.

obj_i

The index of this data object within the dataset.


Method create_cells_list()

Create a list representing the cells in the Seurat object.

Usage

SeuratWrapper$create_cells_list()

Returns

A list that can be converted to JSON.


Method create_cell_sets_list()

Create a list representing the cluster assignments in the Seurat object.

Usage

SeuratWrapper$create_cell_sets_list()

Returns

A list that can be converted to JSON.


Method create_expression_matrix_list()

Create a list representing the cluster assignments in the Seurat object.

Usage

SeuratWrapper$create_expression_matrix_list()

Returns

A list that can be converted to JSON.


Method make_cells_file_def_creator()

Make the file definition creator function for the cells data type.

Usage

SeuratWrapper$make_cells_file_def_creator(dataset_uid, obj_i)

Arguments

dataset_uid

The ID for this dataset.

obj_i

The index of this data object within the dataset.

Returns

A file definition creator function which takes a base_url parameter.


Method make_cell_sets_file_def_creator()

Make the file definition creator function for the cell sets data type.

Usage

SeuratWrapper$make_cell_sets_file_def_creator(dataset_uid, obj_i)

Arguments

dataset_uid

The ID for this dataset.

obj_i

The index of this data object within the dataset.

Returns

A file definition creator function which takes a base_url parameter.


Method make_expression_matrix_file_def_creator()

Make the file definition creator function for the expression matrix data type.

Usage

SeuratWrapper$make_expression_matrix_file_def_creator(dataset_uid, obj_i)

Arguments

dataset_uid

The ID for this dataset.

obj_i

The index of this data object within the dataset.

Returns

A file definition creator function which takes a base_url parameter.


Method clone()

The objects of this class are cloneable with this method.

Usage

SeuratWrapper$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.