2025-04-13

Sepal Length Versus Width

Average Sepal Lengths & Widths by Species

Species Avg Sepal Length (cm) Avg Sepal Width (cm)
Setosa \(5.006\) \(3.428\)
Versicolor \(5.936\) \(2.770\)
Virginica \(6.588\) \(2.974\)

Petal Length Versus Width

Average Petal Lengths & Widths by Species

Species Avg Petal Width (cm) Avg Petal Width (cm)
Setosa \(1.462\) \(0.246\)
Versicolor \(4.260\) \(1.326\)
Virginica \(5.552\) \(2.026\)

Densities by Species

Petal Width x Petal Length x Sepal Length

Code Setup

fig <- plot_ly(iris, x = ~Petal.Width, y = ~Petal.Length,
               z = ~Sepal.Length, color = ~Species, 
               colors = c("#F8766D", "#00BA38", "#619CFF"),
               marker = list(size = 5)) %>%
               add_markers() %>% 
               layout(scene = 
                        list(xaxis = list(
                        title = "Petal Width"),
                        yaxis = list(title = "Petal Length"),
                        zaxis = list(title = "Sepal Length")))

Petal Width x Petal Length x Sepal Length

Figure Output