plotly Scatterplot in R (Example) | Draw Interactive XY-Plot | Change Shape of Dots, Size & Opacity
Автор: Statistics Globe
Загружено: 22 дек. 2021 г.
Просмотров: 1 057 просмотров
How to create an interactive XY-Plot with plotly in the R programming language. More details: https://statisticsglobe.com/plotly-sc...
Profile of Kirby White: https://statisticsglobe.com/kirby-white
R code of this video:
install.packages("plotly")
library(plotly)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers"
)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers",
color = ~Species
)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers",
color = ~Species,
symbol = ~Species
)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers",
color = ~Species,
symbol = ~Species,
size = 3
)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers",
color = ~Species,
symbol = ~Species,
size = ~Petal.Length
)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers",
color = ~Species,
symbol = ~Species,
size = 3,
alpha = .3
)
plot_ly(
data = iris,
x = ~Petal.Length,
y = ~Petal.Width,
type = "scatter",
mode = "markers",
color = ~Species,
symbol = ~Species,
size = 3,
alpha = .65,
text = ~Species
)
Follow me on Social Media:
Facebook – Statistics Globe Page: / statisticsglobecom
Facebook – Group for Discussions & Questions: / statisticsglobe
LinkedIn – Statistics Globe Page: / statisticsglobe
LinkedIn – Group for Discussions & Questions: / 12555223
Twitter: / joachimschork
Music by bensound.com

Доступные форматы для скачивания:
Скачать видео mp4
-
Информация по загрузке: