| add_pareto_emoa_column | R Documentation |
This function calculates the Pareto front for a given set of objectives in a data frame and adds a new column, PARETO_EMOA, which indicates whether each row in the data frame belongs to the Pareto front.
add_pareto_emoa_column(data, objectives)
data |
A data frame containing the data, including the objective columns. |
objectives |
A character vector specifying the names of the objective columns in |
A data frame with the same columns as data, along with an additional column, PARETO_EMOA, which is TRUE for rows that are on the Pareto front and FALSE otherwise.
# Define objective columns
objectives <- c("trust", "predictability", "perceivedSafety", "Comfort")
# Example data frame
main_df <- data.frame(
trust = runif(10),
predictability = runif(10),
perceivedSafety = runif(10),
Comfort = runif(10)
)
# Add the Pareto front column
main_df <- add_pareto_emoa_column(data = main_df, objectives)
head(main_df)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.