data("ordmvnorm")
x <- ordmvnorm[, 3:7]
y <- ordmvnorm$bag_label
bags <- ordmvnorm$bag_name
mdl1 <- misvm_orova(x, y, bags)
# summarize predictions at the bag layer
library(dplyr)
df1 <- bind_cols(y = y, bags = bags, as.data.frame(x))
df1 %>%
bind_cols(predict(mdl1, df1, new_bags = bags, type = "class")) %>%
bind_cols(predict(mdl1, df1, new_bags = bags, type = "raw")) %>%
select(-starts_with("V")) %>%
distinct()
Run the code above in your browser using DataLab