Open Side Menu
Skip to contentBrand Logo
Forums
Inspiration
Ideas
Communities
Blogs
Learning
Support
RegisterSign In
  1. Microsoft Fabric Community
  2. Power BI forums
  3. Galleries
  4. R Script Showcase
Sharon's avatar
Sharon
Icon for Microsoft Employee rankMicrosoft Employee
10 years ago

Association Rules

Description Association rules are ideal to quicly derive insights from large datasets.  The rules are autmatically detected and visualized.    Prerequisites (The sample .pbix files will not...
ScriptInstallPackagesWithWorkaroundsAssorules.R2 KB
Association Rules Showcase_1.0.2.pbix1.1 MB
Advanced Analytics Visualizations
boefraty's avatar
boefraty
Icon for Microsoft Employee rankMicrosoft Employee
9 years ago

The data with 2 columns: "TransactionID" and "Product" is indeed very natural. Attached is the PBIX with R code suited to such input.

The relevant data transformation is in lines

nnn = names(dataset)

transData <- as(split(dataset[,nnn[2]], dataset[,nnn[1]]), "transactions")

 

The data in PBIX is synthetic.

surething's avatar
surething
New Member
9 years ago

Hi, 

 

I'm trying to use the R script to create association rules for transaction ID and item reference in PBI. I used the script you have in the example but it didn't seem to work. any idea why?  

 

Thanks 

  • © 2026 Microsoft
  • Manage cookies
  • Privacy & cookies
  • Terms of use
  • Trademarks
Your Privacy Choices Consumer Health Privacy