Closed garyzhubc closed 1 year ago
Use function addTobca, which has been designed for this purpose. augmented_bca <- addTobca(x = your_bca, tt = "description matrix of the subsets to add"). Then do: belplau(augmented_bca).
How to retrieve these subsets that I want from the belplau table if I have a lot of other subsets? Is there a given order how these subsets are sorted in belplau?
Function "belplau" does no sort. The order is the one of the tt matrix of the bca submitted to belplau.
If you have added subsets via function addTobca, these subsets will appear first. If you want to retrieve specific subsets from your bca, you can do this way:
2.1 Do: table <- outer(c("label1", "label2", "label3"), rownames(result), "==") 2.2 Do: rownumbers <- (apply(table, 2, sum) ) * 1:nrow(result)
Hmm...
I've got zero beliefs on these three subsets. Let me see if there's better ways to use plausible inference.
Which three subsets do you speak of?
If your three subsets are part of a bca obtained from the repeated application of Dempster's Rule on your data, they cannot have zero mass.
If you add a new subset A to your bca (with addTobca function), it has zero mass by definition. It will have a positive belief value if your bca contains one or more subsets of A.
Was this issue resolved by using addTobca function?
Yes, and the right way to retrieve only these subsets as mentioned in a different post.
# select input hypotheses
bel_plau_df_ <- cbind(bel_plau, bpa$spec)
bel_plau_df_selected <- as.data.frame(bel_plau_df_[which(bel_plau_df_[,ncol(bel_plau_df_)] == 1),])
How to calculate belief of a subset that's not one of the subsets given by belplau?