Loadings: Get feature loadings

Description Usage Arguments Examples

View source: R/generics.R

Description

Get feature loadings

Add feature loadings

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
Loadings(object, ...)

Loadings(object, ...) <- value

## S3 method for class 'DimReduc'
Loadings(object, projected = FALSE, ...)

## S3 method for class 'Seurat'
Loadings(object, reduction = "pca", projected = FALSE, ...)

## S3 replacement method for class 'DimReduc'
Loadings(object, projected = TRUE, ...) <- value

Arguments

object

An object

...

Arguments passed to other methods

value

Feature loadings to add

projected

Pull the projected feature loadings?

reduction

Name of reduction to pull feature loadings for

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# Get the feature loadings for a given DimReduc
Loadings(object = pbmc_small[["pca"]])[1:5,1:5]

# Get the feature loadings for a specified DimReduc in a Seurat object
Loadings(object = pbmc_small, reduction = "pca")[1:5,1:5]

# Set the feature loadings for a given DimReduc
new.loadings <- Loadings(object = pbmc_small[["pca"]])
new.loadings <- new.loadings + 0.01
Loadings(object = pbmc_small[["pca"]]) <- new.loadings

lambdamoses/SeuratBasics documentation built on May 6, 2020, 9:32 a.m.