SlideShare uma empresa Scribd logo
1 de 18
Baixar para ler offline
Machine Learning with R
and Tableau
Tableau User Group (TUG)
Greg Armstrong
Blast Analytics & Marketing
garmstrong@blastam.com
TUG | Machine Learning with R and Tableau
Agenda
Machine Learning with R and Tableau
2
1. What is Machine Learning?
2. What is R?
3. Live Examples using Tableau and R
TUG | Machine Learning with R and Tableau
Machine Learning
What is machine learning?
3
Machine learning explores
the study and construction
of algorithms that can
learn from and make
predictions on data.
• Classification
• Regression
• Segmentation
Common Methods
TUG | Machine Learning with R and Tableau 4
Regression
Machine Learning
Supervised Learning
Classification
X
Y
X
Y
TUG | Machine Learning with R and Tableau 5
Segmentation (cluster)
Machine Learning
Unsupervised Learning
X
Y
TUG | Machine Learning with R and Tableau
Machine Learning
Marketing use cases
6
• Predicting Lifetime Value (LTV)
• Predicting Churn
• Customer segmentation
• Product recommendations
I like it. I like it a lot!
TUG | Machine Learning with R and Tableau
Machine Learning
Finance use cases
7
• Predicting credit risk
• Treasury or currency risk
• Fraud detection
• Accounts Payable Recovery
“Because a large font makes profits look bigger.”
TUG | Machine Learning with R and Tableau
Machine Learning
Human Resources use cases
8
• Resume screening
• Employee churn
• Training recommendation
• Talent management
“I pruned a tree once, so technically I’m allowed
to put ‘branch manager’ on my resume”
TUG | Machine Learning with R and Tableau
Machine Learning
Web Search
9
… and predictive text
algorithms to fill in the most
common keyword search
terms.
Google uses machine
learning algorithms to serve
up the correct search even
when the search terms are
vastly misspelled.
TUG | Machine Learning with R and Tableau
Machine Learning
Social Networks
10
TUG | Machine Learning with R and Tableau
Machine Learning
Spam Filtering
11
No Spam
TUG | Machine Learning with R and Tableau
Machine Learning
Research - Fishers Iris
12
Based on Ronald Fisher’s 1936 paper
the idea was to perform statistical
classification on the Iris flower
data set.
Petal widthPetal length
SepalwidthSepallength
TUG | Machine Learning with R and Tableau
ahhRRRR!
What is R?
13
• Data manipulation
• Statistical modeling
• Visualization tool
• Open Source
R is a language for statistical analysis and
data visualization.
TUG | Machine Learning with R and Tableau
R Studio, R & Tableau
A brief introduction
14
+
TUG | Machine Learning with R and Tableau
Tableau + R
What did we discover?
15
Customer Segmentation (clusters)
1. There are some big spenders in the Red group,
who may not have purchased in a while.
2. Our most profitable customers seem to be older
with higher incomes. (Blue group)
Forecasting (linear regression)
1. Tableau forecasting is very good.
2. More flexibility with R forecasting.
TUG | Machine Learning with R and Tableau
Tableau User Group (TUG)
Machine Learning with R and Tableau
16
Questions?
Thank you!
Phone (888) 252-7866 Email sales@blastam.comWeb www.blastam.com
Roseville Office
6020 West Oaks Blvd, Suite 260
Rocklin, CA 95765
San Francisco Office
625 Second Street, Suite 280
San Francisco, CA 94107
New York Office
261 Madison Ave, 9th Floor
New York, NY 10016
Seattle Office
500 Yale Avenue North
Seattle, WA 98109
Los Angeles Office
7083 Hollywood Boulevard
Los Angeles, CA 90028
TUG | Machine Learning with R and Tableau
Calculated Fields
Tableau Calculated Fields for R
18
SCRIPT_INT("
## Sets the seed
set.seed( .arg7[1])
## Studentizes the variables
day <- ( .arg1 - mean(.arg1) )/ sd(.arg1)
mos <- ( .arg2 - mean(.arg2) )/ sd(.arg2)
dis <- ( .arg3 - mean(.arg3) )/ sd(.arg3)
inc <- ( .arg4 - mean(.arg4) )/ sd(.arg4)
age <- ( .arg5 - mean(.arg5) )/ sd(.arg5)
dat <- cbind(day, mos, dis, inc, age)
day <- .arg6[1]
## Creates the clusters
kmeans(dat, day)$cluster
",
MIN([Days Since Last Order]),
[Months as Customer],
AVG([Discount]),
MAX([Income]),
MAX([Age]),
[clusters],
[seed]
)
K-means cluster for customer segmentation
SCRIPT_STR('hello <- "Hello TUG!"', ATTR([R
Result]))
Pass string to R with a parameter
SCRIPT_INT("as.integer(.arg1 * 2)", [R Variable])
Pass calculation to R based on parameter
SCRIPT_BOOL("
print('******************************************
*********************')
print('the vector sent was')
print(.arg1)
print('with length')
print(length(.arg1))
TRUE
",
SUM([Sales])
)
Print to console R arguments

Mais conteúdo relacionado

Destaque

Creating a Culture of CareerFinal 111015
Creating a Culture of CareerFinal 111015Creating a Culture of CareerFinal 111015
Creating a Culture of CareerFinal 111015Poonam Sahotra
 
Data first with Tableau [FutureStack16]
Data first with Tableau [FutureStack16]Data first with Tableau [FutureStack16]
Data first with Tableau [FutureStack16]New Relic
 
whitepaper_advanced_analytics_with_tableau_eng
whitepaper_advanced_analytics_with_tableau_engwhitepaper_advanced_analytics_with_tableau_eng
whitepaper_advanced_analytics_with_tableau_engS. Hanau
 
Turismo 2.0 e nicchie di mercato
Turismo 2.0 e nicchie di mercatoTurismo 2.0 e nicchie di mercato
Turismo 2.0 e nicchie di mercatoForlani Fabio
 
Machine Learning with R and Tableau
Machine Learning with R and TableauMachine Learning with R and Tableau
Machine Learning with R and TableauKayden Kelly
 
Tableau Customer Presentation
Tableau Customer PresentationTableau Customer Presentation
Tableau Customer PresentationSplunk
 

Destaque (8)

BI_BigData_Titulo
BI_BigData_TituloBI_BigData_Titulo
BI_BigData_Titulo
 
Creating a Culture of CareerFinal 111015
Creating a Culture of CareerFinal 111015Creating a Culture of CareerFinal 111015
Creating a Culture of CareerFinal 111015
 
Data first with Tableau [FutureStack16]
Data first with Tableau [FutureStack16]Data first with Tableau [FutureStack16]
Data first with Tableau [FutureStack16]
 
Tableau Suite Analysis
Tableau Suite Analysis Tableau Suite Analysis
Tableau Suite Analysis
 
whitepaper_advanced_analytics_with_tableau_eng
whitepaper_advanced_analytics_with_tableau_engwhitepaper_advanced_analytics_with_tableau_eng
whitepaper_advanced_analytics_with_tableau_eng
 
Turismo 2.0 e nicchie di mercato
Turismo 2.0 e nicchie di mercatoTurismo 2.0 e nicchie di mercato
Turismo 2.0 e nicchie di mercato
 
Machine Learning with R and Tableau
Machine Learning with R and TableauMachine Learning with R and Tableau
Machine Learning with R and Tableau
 
Tableau Customer Presentation
Tableau Customer PresentationTableau Customer Presentation
Tableau Customer Presentation
 

Último

Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
Test Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendTest Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendArshad QA
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software DevelopersVinodh Ram
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerThousandEyes
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...OnePlan Solutions
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about usDynamic Netsoft
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number SystemsJheuzeDellosa
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Active Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfActive Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfCionsystems
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comFatema Valibhai
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfjoe51371421
 

Último (20)

Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Test Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendTest Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and Backend
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software Developers
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about us
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number Systems
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Active Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfActive Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdf
 
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.comHR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdf
 

Machine Learning with R and Tableau

  • 1. Machine Learning with R and Tableau Tableau User Group (TUG) Greg Armstrong Blast Analytics & Marketing garmstrong@blastam.com
  • 2. TUG | Machine Learning with R and Tableau Agenda Machine Learning with R and Tableau 2 1. What is Machine Learning? 2. What is R? 3. Live Examples using Tableau and R
  • 3. TUG | Machine Learning with R and Tableau Machine Learning What is machine learning? 3 Machine learning explores the study and construction of algorithms that can learn from and make predictions on data. • Classification • Regression • Segmentation Common Methods
  • 4. TUG | Machine Learning with R and Tableau 4 Regression Machine Learning Supervised Learning Classification X Y X Y
  • 5. TUG | Machine Learning with R and Tableau 5 Segmentation (cluster) Machine Learning Unsupervised Learning X Y
  • 6. TUG | Machine Learning with R and Tableau Machine Learning Marketing use cases 6 • Predicting Lifetime Value (LTV) • Predicting Churn • Customer segmentation • Product recommendations I like it. I like it a lot!
  • 7. TUG | Machine Learning with R and Tableau Machine Learning Finance use cases 7 • Predicting credit risk • Treasury or currency risk • Fraud detection • Accounts Payable Recovery “Because a large font makes profits look bigger.”
  • 8. TUG | Machine Learning with R and Tableau Machine Learning Human Resources use cases 8 • Resume screening • Employee churn • Training recommendation • Talent management “I pruned a tree once, so technically I’m allowed to put ‘branch manager’ on my resume”
  • 9. TUG | Machine Learning with R and Tableau Machine Learning Web Search 9 … and predictive text algorithms to fill in the most common keyword search terms. Google uses machine learning algorithms to serve up the correct search even when the search terms are vastly misspelled.
  • 10. TUG | Machine Learning with R and Tableau Machine Learning Social Networks 10
  • 11. TUG | Machine Learning with R and Tableau Machine Learning Spam Filtering 11 No Spam
  • 12. TUG | Machine Learning with R and Tableau Machine Learning Research - Fishers Iris 12 Based on Ronald Fisher’s 1936 paper the idea was to perform statistical classification on the Iris flower data set. Petal widthPetal length SepalwidthSepallength
  • 13. TUG | Machine Learning with R and Tableau ahhRRRR! What is R? 13 • Data manipulation • Statistical modeling • Visualization tool • Open Source R is a language for statistical analysis and data visualization.
  • 14. TUG | Machine Learning with R and Tableau R Studio, R & Tableau A brief introduction 14 +
  • 15. TUG | Machine Learning with R and Tableau Tableau + R What did we discover? 15 Customer Segmentation (clusters) 1. There are some big spenders in the Red group, who may not have purchased in a while. 2. Our most profitable customers seem to be older with higher incomes. (Blue group) Forecasting (linear regression) 1. Tableau forecasting is very good. 2. More flexibility with R forecasting.
  • 16. TUG | Machine Learning with R and Tableau Tableau User Group (TUG) Machine Learning with R and Tableau 16 Questions? Thank you!
  • 17. Phone (888) 252-7866 Email sales@blastam.comWeb www.blastam.com Roseville Office 6020 West Oaks Blvd, Suite 260 Rocklin, CA 95765 San Francisco Office 625 Second Street, Suite 280 San Francisco, CA 94107 New York Office 261 Madison Ave, 9th Floor New York, NY 10016 Seattle Office 500 Yale Avenue North Seattle, WA 98109 Los Angeles Office 7083 Hollywood Boulevard Los Angeles, CA 90028
  • 18. TUG | Machine Learning with R and Tableau Calculated Fields Tableau Calculated Fields for R 18 SCRIPT_INT(" ## Sets the seed set.seed( .arg7[1]) ## Studentizes the variables day <- ( .arg1 - mean(.arg1) )/ sd(.arg1) mos <- ( .arg2 - mean(.arg2) )/ sd(.arg2) dis <- ( .arg3 - mean(.arg3) )/ sd(.arg3) inc <- ( .arg4 - mean(.arg4) )/ sd(.arg4) age <- ( .arg5 - mean(.arg5) )/ sd(.arg5) dat <- cbind(day, mos, dis, inc, age) day <- .arg6[1] ## Creates the clusters kmeans(dat, day)$cluster ", MIN([Days Since Last Order]), [Months as Customer], AVG([Discount]), MAX([Income]), MAX([Age]), [clusters], [seed] ) K-means cluster for customer segmentation SCRIPT_STR('hello <- "Hello TUG!"', ATTR([R Result])) Pass string to R with a parameter SCRIPT_INT("as.integer(.arg1 * 2)", [R Variable]) Pass calculation to R based on parameter SCRIPT_BOOL(" print('****************************************** *********************') print('the vector sent was') print(.arg1) print('with length') print(length(.arg1)) TRUE ", SUM([Sales]) ) Print to console R arguments