Skip to content

Commit 1549dcb

Browse files
authored
Merge pull request #8878 from satijalab/develop
Release/5.1.0
2 parents c54e57d + 95583fd commit 1549dcb

File tree

91 files changed

+2245
-325
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

91 files changed

+2245
-325
lines changed

DESCRIPTION

+5-3
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
Package: Seurat
2-
Version: 5.0.3
3-
Date: 2024-03-18
2+
Version: 5.1.0
3+
Date: 2024-05-08
44
Title: Tools for Single Cell Genomics
55
Description: A toolkit for quality control, analysis, and exploration of single cell RNA sequencing data. 'Seurat' aims to enable users to identify and interpret sources of heterogeneity from single cell transcriptomic measurements, and to integrate diverse types of single cell data. See Satija R, Farrell J, Gennert D, et al (2015) <doi:10.1038/nbt.3192>, Macosko E, Basu A, Satija R, et al (2015) <doi:10.1016/j.cell.2015.05.002>, Stuart T, Butler A, et al (2019) <doi:10.1016/j.cell.2019.05.031>, and Hao, Hao, et al (2020) <doi:10.1101/2020.10.12.335331> for more details.
66
Authors@R: c(
77
person(given = "Andrew", family = "Butler", email = "[email protected]", role = "ctb", comment = c(ORCID = "0000-0003-3608-0463")),
88
person(given = "Saket", family = "Choudhary", email = "[email protected]", role = "ctb", comment = c(ORCID = "0000-0001-5202-7633")),
9+
person(given = 'David', family = 'Collins', email = '[email protected]', role = 'ctb', comment = c(ORCID = '0000-0001-9243-7821')),
910
person(given = "Charlotte", family = "Darby", email = "[email protected]", role = "ctb", comment = c(ORCID = "0000-0003-2195-5300")),
1011
person(given = "Jeff", family = "Farrell", email = "[email protected]", role = "ctb"),
1112
person(given = "Isabella", family = "Grabski", email = "[email protected]", role = "ctb", comment = c(ORCID = "0000-0002-0616-5469")),
@@ -34,7 +35,7 @@ Additional_repositories: https://satijalab.r-universe.dev, https://bnprks.r-univ
3435
Depends:
3536
R (>= 4.0.0),
3637
methods,
37-
SeuratObject (>= 5.0.0)
38+
SeuratObject (>= 5.0.2)
3839
Imports:
3940
cluster,
4041
cowplot,
@@ -117,6 +118,7 @@ RoxygenNote: 7.3.1
117118
Encoding: UTF-8
118119
Suggests:
119120
ape,
121+
arrow,
120122
BPCells,
121123
rsvd,
122124
testthat,

NAMESPACE

+7
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ S3method(GetImage,VisiumV1)
5252
S3method(GetTissueCoordinates,STARmap)
5353
S3method(GetTissueCoordinates,SlideSeq)
5454
S3method(GetTissueCoordinates,VisiumV1)
55+
S3method(GetTissueCoordinates,VisiumV2)
5556
S3method(HVFInfo,SCTAssay)
5657
S3method(IntegrateEmbeddings,IntegrationAnchorSet)
5758
S3method(IntegrateEmbeddings,TransferAnchorSet)
@@ -133,6 +134,7 @@ S3method(ScaleData,Seurat)
133134
S3method(ScaleData,StdAssay)
134135
S3method(ScaleData,default)
135136
S3method(ScaleFactors,VisiumV1)
137+
S3method(ScaleFactors,VisiumV2)
136138
S3method(ScoreJackStraw,DimReduc)
137139
S3method(ScoreJackStraw,JackStrawData)
138140
S3method(ScoreJackStraw,Seurat)
@@ -153,6 +155,7 @@ S3method(components,SCTAssay)
153155
S3method(dim,STARmap)
154156
S3method(dim,SlideSeq)
155157
S3method(dim,VisiumV1)
158+
S3method(dim,VisiumV2)
156159
S3method(fortify,Centroids)
157160
S3method(fortify,Molecules)
158161
S3method(fortify,Segmentation)
@@ -353,7 +356,9 @@ export(PurpleAndYellow)
353356
export(RPCAIntegration)
354357
export(Radius)
355358
export(Read10X)
359+
export(Read10X_Coordinates)
356360
export(Read10X_Image)
361+
export(Read10X_ScaleFactors)
357362
export(Read10X_h5)
358363
export(Read10X_probe_metadata)
359364
export(ReadAkoya)
@@ -463,9 +468,11 @@ exportClasses(SeuratCommand)
463468
exportClasses(SpatialImage)
464469
exportClasses(TransferAnchorSet)
465470
exportClasses(VisiumV1)
471+
exportClasses(VisiumV2)
466472
importClassesFrom(Matrix,dgCMatrix)
467473
importClassesFrom(SeuratObject,Assay)
468474
importClassesFrom(SeuratObject,DimReduc)
475+
importClassesFrom(SeuratObject,FOV)
469476
importClassesFrom(SeuratObject,Graph)
470477
importClassesFrom(SeuratObject,JackStrawData)
471478
importClassesFrom(SeuratObject,Neighbor)

NEWS.md

+18
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,21 @@
1+
# Seurat 5.1.0 (2024-05-08)
2+
3+
## Changes
4+
- Updated interactive `SpatialDimPlot`s to display spatial coordinates
5+
- Updated `BuildClusterTree` to `PseudobulkExpression(..., method = "aggregate")` instead of `AverageExpression`
6+
- Fixed `SpatialPlot` to properly handle images with shared cells
7+
- Added `cluster.name` parameter to `BuildNicheAssay`
8+
- Added `VisiumV2` class, inherits `SeuratObject::FOV`, returned by `Load10X_Spatial`
9+
- Updated `Load10X_Spatial` to support loading Visium HD datasets - added `bin.size` parameter
10+
- Updated `Read10X_Coordinates` to handle new `tissue_coordinates.parquet` files
11+
- Added `shape` parameter to `SpatialPlot` and wrappers: `SpatialFeaturePlot` and `SpatialDimPlot`
12+
- Added `image.scale` parameter to `SpatialPlot` and related functions: `SpatialFeaturePlot`/`ISpatialFeaturePlot` and `SpatialDimPlot`/`ISpatialDimPlot`
13+
- Restored `image.name` parameter to `Read10X_Image`
14+
- Added `scale` parameter to `Radius.VisiumV1`
15+
- Fixed calculation of `spot.radius` attribute for `VisiumV1` instance returned by `Read10X_Image` — replace `scale.factors$fiducial` with `scale.factors$spot`
16+
- Added `Read10X_Coordinates` and `Read10X_ScaleFactors`
17+
- Fixed `SpatialPlot` to properly handle mutli-assay `Seurat` instances
18+
119
# Seurat 5.0.3 (2024-03-18)
220

321
## Changes

R/convenience.R

+10-2
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,9 @@ SpatialDimPlot <- function(
258258
pt.size.factor = 1.6,
259259
alpha = c(1, 1),
260260
image.alpha = 1,
261-
stroke = 0.25,
261+
image.scale = "lowres",
262+
shape = 21,
263+
stroke = NA,
262264
label.box = TRUE,
263265
interactive = FALSE,
264266
information = NULL
@@ -281,6 +283,8 @@ SpatialDimPlot <- function(
281283
pt.size.factor = pt.size.factor,
282284
alpha = alpha,
283285
image.alpha = image.alpha,
286+
image.scale = image.scale,
287+
shape = shape,
284288
stroke = stroke,
285289
label.box = label.box,
286290
interactive = interactive,
@@ -307,7 +311,9 @@ SpatialFeaturePlot <- function(
307311
pt.size.factor = 1.6,
308312
alpha = c(1, 1),
309313
image.alpha = 1,
310-
stroke = 0.25,
314+
image.scale = "lowres",
315+
shape = 21,
316+
stroke = NA,
311317
interactive = FALSE,
312318
information = NULL
313319
) {
@@ -325,6 +331,8 @@ SpatialFeaturePlot <- function(
325331
pt.size.factor = pt.size.factor,
326332
alpha = alpha,
327333
image.alpha = image.alpha,
334+
image.scale = image.scale,
335+
shape = shape,
328336
stroke = stroke,
329337
interactive = interactive,
330338
information = information

R/differential_expression.R

+1-1
Original file line numberDiff line numberDiff line change
@@ -910,9 +910,9 @@ FindMarkers.DimReduc <- function(
910910
#'
911911
FindMarkers.Seurat <- function(
912912
object,
913-
latent.vars = NULL,
914913
ident.1 = NULL,
915914
ident.2 = NULL,
915+
latent.vars = NULL,
916916
group.by = NULL,
917917
subset.ident = NULL,
918918
assay = NULL,

R/generics.R

+1-1
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,6 @@ IntegrateEmbeddings <- function(anchorset, ...) {
321321
#'
322322
#' @export
323323
#'
324-
#'
325324
LeverageScore <- function(object, ...) {
326325
UseMethod(generic = 'LeverageScore', object = object)
327326
}
@@ -454,6 +453,7 @@ ProjectUMAP <- function(query, ...) {
454453
#'
455454
#' @rdname PseudobulkExpression
456455
#' @export PseudobulkExpression
456+
#' @concept utilities
457457
#'
458458
PseudobulkExpression <- function(object, ...) {
459459
UseMethod(generic = "PseudobulkExpression", object = object)

R/integration.R

+23-5
Original file line numberDiff line numberDiff line change
@@ -981,7 +981,7 @@ FindTransferAnchors <- function(
981981
LayerData(object = combined.ob, layer = data.layer.name) <- layer.data # set layer data
982982
}
983983
colnames(x = orig.loadings) <- paste0("ProjectPC_", 1:ncol(x = orig.loadings))
984-
984+
985985
combined.ob[["pcaproject"]] <- combined.pca
986986
Loadings(object = combined.ob[["pcaproject"]], projected = FALSE) <- orig.loadings[, dims]
987987
Loadings(object = combined.ob[["pcaproject"]]) <- orig.loadings[, dims]
@@ -1901,6 +1901,7 @@ IntegrateEmbeddings.TransferAnchorSet <- function(
19011901
#' @importFrom Matrix t
19021902
#'
19031903
#' @export
1904+
#' @concept integration
19041905
#'
19051906
ProjectIntegration <- function(
19061907
object,
@@ -3056,6 +3057,7 @@ SelectIntegrationFeatures <- function(
30563057
#' @param ... Arguments passed on to \code{method}
30573058
#'
30583059
#' @export
3060+
#' @concept integration
30593061
#'
30603062
SelectIntegrationFeatures5 <- function(
30613063
object,
@@ -3088,6 +3090,7 @@ SelectIntegrationFeatures5 <- function(
30883090
#' @param ... Arguments passed on to \code{method}
30893091
#'
30903092
#' @export
3093+
#' @concept integration
30913094
#'
30923095
SelectSCTIntegrationFeatures <- function(
30933096
object,
@@ -6506,6 +6509,7 @@ ValidateParams_IntegrateEmbeddings_TransferAnchors <- function(
65066509
#' @importFrom Matrix sparseMatrix
65076510
#'
65086511
#' @export
6512+
#' @concept integration
65096513
#'
65106514
NNtoGraph <- function(
65116515
nn.object,
@@ -6670,7 +6674,9 @@ FindAssayAnchor <- function(
66706674
#'
66716675
#' @importFrom MASS ginv
66726676
#' @return Returns a object list in which each object has a bridge cell derived assay
6677+
#'
66736678
#' @export
6679+
#' @concept integration
66746680
#'
66756681
BridgeCellsRepresentation <- function(object.list,
66766682
bridge.object,
@@ -6822,7 +6828,8 @@ BridgeCellsRepresentation <- function(object.list,
68226828
#' @return Returns an \code{\link{AnchorSet}} object that can be used as input to
68236829
#' \code{\link{IntegrateEmbeddings}}.or \code{\link{MapQuery}}
68246830
#'
6825-
6831+
#' @keywords internal
6832+
#'
68266833
FindBridgeAnchor <- function(object.list,
68276834
bridge.object,
68286835
object.reduction,
@@ -7346,7 +7353,10 @@ SmoothLabels <- function(labels, clusters) {
73467353
#' @param verbose Print progress and message
73477354
#'
73487355
#' @return Returns a query-only or query-reference combined seurat object
7356+
#'
73497357
#' @export
7358+
#' @concept integration
7359+
#'
73507360
ProjectDimReduc <- function(query,
73517361
reference,
73527362
mode = c('pcaproject', 'lsiproject'),
@@ -7492,11 +7502,13 @@ ProjectDimReduc <- function(query,
74927502
#' @param laplacian.reduction.dims Number of dimensions used for graph laplacian eigenspace (default is 50)
74937503
#' @param verbose Print progress and message (default is TRUE)
74947504
#'
7495-
#' @export
74967505
#' @return Returns a \code{BridgeReferenceSet} that can be used as input to
74977506
#' \code{\link{FindBridgeTransferAnchors}}.
74987507
#' The parameters used are stored in the \code{BridgeReferenceSet} as well
74997508
#'
7509+
#' @export
7510+
#' @concept integration
7511+
#'
75007512
PrepareBridgeReference <- function (
75017513
reference,
75027514
bridge,
@@ -7642,11 +7654,13 @@ PrepareBridgeReference <- function (
76427654
#' }
76437655
#' @param verbose Print messages and progress
76447656
#'
7645-
#' @export
76467657
#' @return Returns an \code{AnchorSet} object that can be used as input to
76477658
#' \code{\link{TransferData}}, \code{\link{IntegrateEmbeddings}} and
76487659
#' \code{\link{MapQuery}}.
76497660
#'
7661+
#' @export
7662+
#' @concept integration
7663+
#'
76507664
FindBridgeTransferAnchors <- function(
76517665
extended.reference,
76527666
query,
@@ -7725,10 +7739,12 @@ FindBridgeTransferAnchors <- function(
77257739
#' }
77267740
#' }
77277741
#'
7728-
#' @export
77297742
#' @return Returns an \code{AnchorSet} object that can be used as input to
77307743
#' \code{\link{IntegrateEmbeddings}}.
77317744
#'
7745+
#' @export
7746+
#' @concept integration
7747+
#'
77327748
FindBridgeIntegrationAnchors <- function(
77337749
extended.reference,
77347750
query,
@@ -7807,6 +7823,7 @@ FindBridgeIntegrationAnchors <- function(
78077823
#' @importFrom rlang exec
78087824
#' @return Returns a Seurat object with integrated dimensional reduction
78097825
#' @export
7826+
#' @concept integration
78107827
#'
78117828
FastRPCAIntegration <- function(
78127829
object.list,
@@ -7912,6 +7929,7 @@ FastRPCAIntegration <- function(
79127929
#' @importFrom Matrix t
79137930
#'
79147931
#' @export
7932+
#' @concept integration
79157933
#'
79167934
UnSketchEmbeddings <- function(
79177935
atom.data,

R/integration5.R

+4
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ attr(x = HarmonyIntegration, which = 'Seurat.method') <- 'integration'
158158
#'
159159
#' @inheritParams RPCAIntegration
160160
#' @export
161+
#' @concept integration
161162
#'
162163
#' @examples
163164
#' \dontrun{
@@ -342,6 +343,8 @@ attr(x = CCAIntegration, which = 'Seurat.method') <- 'integration'
342343
#' @param ... Arguments passed on to \code{FindIntegrationAnchors}
343344
#' @export
344345
#'
346+
#' @concept utilities
347+
#'
345348
RPCAIntegration <- function(
346349
object = NULL,
347350
assay = NULL,
@@ -444,6 +447,7 @@ attr(x = RPCAIntegration, which = 'Seurat.method') <- 'integration'
444447
#' @inheritParams IntegrateEmbeddings
445448
#' @param ... Arguments passed on to \code{FindIntegrationAnchors}
446449
#' @export
450+
#' @concept integration
447451
#'
448452
JointPCAIntegration <- function(
449453
object = NULL,

0 commit comments

Comments
 (0)