Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

VariableFeatures

Highly Variable Features


Description

Get and set variable feature information for an Assay object. HVFInfo and VariableFeatures utilize generally variable features, while SVFInfo and SpatiallyVariableFeatures are restricted to spatially variable features

Usage

HVFInfo(object, selection.method, status = FALSE, ...)

VariableFeatures(object, selection.method = NULL, ...)

VariableFeatures(object, ...) <- value

SVFInfo(object, selection.method, status, ...)

SpatiallyVariableFeatures(object, selection.method, ...)

## S3 method for class 'Seurat'
HVFInfo(object, selection.method = NULL, status = FALSE, assay = NULL, ...)

## S3 method for class 'Seurat'
VariableFeatures(object, selection.method = NULL, assay = NULL, ...)

## S3 replacement method for class 'Seurat'
VariableFeatures(object, assay = NULL, ...) <- value

## S3 method for class 'Seurat'
SVFInfo(
  object,
  selection.method = c("markvariogram", "moransi"),
  status = FALSE,
  assay = NULL,
  ...
)

## S3 method for class 'Seurat'
SpatiallyVariableFeatures(
  object,
  selection.method = "markvariogram",
  assay = NULL,
  decreasing = TRUE,
  ...
)

## S3 method for class 'Assay'
HVFInfo(object, selection.method, status = FALSE, ...)

## S3 method for class 'Assay'
SpatiallyVariableFeatures(
  object,
  selection.method = "markvariogram",
  decreasing = TRUE,
  ...
)

## S3 method for class 'Assay'
SVFInfo(
  object,
  selection.method = c("markvariogram", "moransi"),
  status = FALSE,
  ...
)

## S3 method for class 'Assay'
VariableFeatures(object, selection.method = NULL, ...)

## S3 replacement method for class 'Assay'
VariableFeatures(object, ...) <- value

Arguments

object

An object

selection.method

Which method to pull. For HVFInfo and VariableFeatures, choose one from one of the following:

  • “vst”

  • “sctransform” or “sct”

  • “mean.var.plot”, “dispersion”, “mvp”, or “disp”

For SVFInfo and SpatiallyVariableFeatures, choose from:

  • “markvariogram”

  • “moransi”

status

Add variable status to the resulting data frame

...

Arguments passed to other methods

value

A character vector of variable features

assay

Name of assay to pull highly variable feature information for

decreasing

Return features in decreasing order (most spatially variable first).

Value

HVFInfo: A data frame with feature means, dispersion, and scaled dispersion

VariableFeatures: a vector of the variable features

SVFInfo: a data frame with the spatially variable features

SpatiallyVariableFeatures: a character vector of the spatially variable features

Examples

# Get the HVF info from a specific Assay in a Seurat object
HVFInfo(object = pbmc_small, assay = "RNA")[1:5, ]

# Get the HVF info directly from an Assay object
HVFInfo(pbmc_small[["RNA"]], selection.method = 'vst')[1:5, ]

SeuratObject

Data Structures for Single Cell Data

v4.0.1
GPL-3
Authors
Rahul Satija [aut] (<https://orcid.org/0000-0001-9448-8833>), Andrew Butler [aut] (<https://orcid.org/0000-0003-3608-0463>), Paul Hoffman [aut, cre] (<https://orcid.org/0000-0002-7693-8957>), Tim Stuart [aut] (<https://orcid.org/0000-0002-3044-0897>), Jeff Farrell [ctb], Shiwei Zheng [ctb] (<https://orcid.org/0000-0001-6682-6743>), Christoph Hafemeister [ctb] (<https://orcid.org/0000-0001-6365-8254>), Patrick Roelli [ctb], Yuhan Hao [ctb] (<https://orcid.org/0000-0002-1810-0822>)
Initial release
2021-05-07

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.