Learn R Programming

Rfuzzycoco (version 0.1.0)

fs_rules_to_df: format the fuzzy rules as a data frame

Description

format the fuzzy rules as a data frame

Usage

fs_rules_to_df(fuzzy_system_desc)

Value

a data frame, one row per rule, including the default rule, in columns the input and output variables. The values are the corresponding fuzzy set number.

Arguments

fuzzy_system_desc

a fuzzy system description as a named list

See Also

Other fit_utils: fit_to_df(), fs_used_vars_to_df()

Examples

Run this code
model <- fuzzycoco("regression", example_mtcars()$params, seed = 123)
df <- mtcars[c("mpg", "hp", "wt", "qsec")]
fit <- fit(model, qsec ~ ., df, seed = 456, max_generations = 10, progress = FALSE)

print(fs_rules_to_df(fit$fuzzy_system))

Run the code above in your browser using DataLab