forked from Dragonmasterx87/seurat
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathHoverLocator.Rd
35 lines (29 loc) · 973 Bytes
/
HoverLocator.Rd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plotting_utilities.R
\name{HoverLocator}
\alias{HoverLocator}
\title{Hover Locator}
\usage{
HoverLocator(plot, data.plot, features.info = NULL, dark.theme = FALSE, ...)
}
\arguments{
\item{plot}{A ggplot2 plot}
\item{data.plot}{The oridinal data that went into the ggplot2 plot}
\item{features.info}{An optional dataframe or matrix of extra information to be displayed on hover}
\item{dark.theme}{Plot using a dark theme?}
\item{...}{Extra parameters to be passed to plotly::layout}
}
\description{
Get quick information from a scatterplot by hovering over points
}
\examples{
\dontrun{
df <- data.frame(x = rnorm(n = 100, mean = 20, sd = 2), y = rbinom(n = 100, size = 100, prob = 0.2))
p <- ggplot(data = df, mapping = aes(x = x, y = y)) + geom_point(mapping = aes(color = 'red'))
HoverLocator(plot = p, data.plot = df)
}
}
\seealso{
\code{plotly::layout}
\code{ggplot2::ggplot_build}
}