plot_sites_scatter_H: Plot H against Date

View source: R/plot_sites_scatter_H.R

plot_sites_scatter_HR Documentation

Plot H against Date

Description

Plot Shannon's H on the Y axis and dates on the X axis with scaled spacing for each date and scattered points.

Usage

plot_sites_scatter_H(
  clusterised_object,
  xlabel = "Date",
  ylabel = "Diversity (H)",
  main_title = "Shannon's H over Time"
)

Arguments

clusterised_object

An object created by the clusterise_sites function.

xlabel

The X axis label with "Date" as default.

ylabel

The Y axis label with "Diversity (H)" as default.

main_title

The main label with "Shannon's H over Time" as default.

Value

Returns a ggplot2 scatter plot in the plot panel, showing the relationship between dates and diversity index values.

Examples

# create a scatter plot showing the diversity over time at the Caquetá province
Colombia_Caquetá_dataframe <- subset(Colombia, stateProvince == "Caquetá")

clusterised_Caquetá <- clusterise_sites(dataframe = Colombia_Caquetá_dataframe,
                                       cluster_min_length = 30,
                                       group_radius = 20000
)

plot_sites_scatter_H(clusterised_Caquetá)

DivInsight documentation built on Aug. 12, 2023, 9:06 a.m.