Untitled

 avatar
unknown
plain_text
5 months ago
431 B
8
Indexable
vec <- c(5, 3, 9, 7, 8)

# Plot

plot(vec, type="o", col="blue", main="Plot Example")
# Histogram
hist(vec, col="green", main="Histogram Example")
# Line chart
plot(vec, type="l", col="red", main="Line Chart Example")
# Pie chart
pie(vec, main="Pie Chart Example")
# Boxplot
boxplot(vec, main="Boxplot Example")
# Scatterplot
x <- c(1, 2, 3, 4, 5)
y <- vec
plot(x, y, main="Scatterplot Example", col="blue", pch=19)
Editor is loading...
Leave a Comment