SlideShare une entreprise Scribd logo
1  sur  29
Télécharger pour lire hors ligne
Joint
Webinar #5
Barcelona Data Science and Machine Learning Meetup
Budapest Deep Learning Reading Seminar
Budapest Data Science Meetup
&
Want to give a talk,
support or …?
joint-meetup@googlegroups.com
Website – xeurope.carrd.co
YouTube – tiny.cc/XWebYT
DEVELOPING INTELLIGENCE POWERED BY DATA
MULTI-STATE CHURN ANALYSIS
WITH A SUBSCRIPTION PRODUCT
WHO IS THIS GUY?
MARCIN KOSIŃSKI
- WARSAW RUG
- R BLOGGER R-ADDICT.COM
- WHYR.PL/2020/
MARCIN@GRADIENTMETRICS.COM
WE’RE GRADIENT:
A crew of quantitative marketers
and technologists that gather hard
data and build robust statistical
models to guide organizations
through their most difficult
decisions.
We’re confirmed data geeks,
but word on the street is that we’re
easy to work with and pretty fun,
too.
meet you!
Nice to
GRADIENTMETRICS.COM
A branch of statistics for analyzing the
expected duration of time until one
or more events happen.
Examples
1. A death of the patient.
2. A deactivation of the service.
3. An accident on the road.
4. The device failure.
5. An employee leaving the company.
6. A customer cancelling subscription.
TALKING
LET'S START
SURVIVAL ANALYSIS
DEFINITION & EXAMPLES
What’s the probability an event will (not)
occur after a specific period of time?
Which characteristics indicate a reduced or
increased risk of occurrence of an event?
What periods of time are most (or least)
exposed to the risk of an event?
ASKING
LET'S START
SURVIVAL ANALYSIS
QUESTIONS IT (MIGHT) ANSWER
Data
1. Censoring.
2. Interval data.
3. Observations may not be
independent.
4. Time varying features.
Events
1. Recurring events - one event might
occur multiple times.
2. Competing risks - one of multiple
events might occur.
3. A multi-state (cyclic/acyclic) nature
of the process.
THE SCENARIO
DEPENDING ON
SURVIVAL ANALYSIS
CHALLENGES IT FACES
HEAD OF THE DATA
ID Start Date End Date Status
1 2018-01-28 2018-02-22 Censoring
2 2017-12-16 2018-01-08 Event
3 2017-12-09 2018-01-06 Censoring
4 2018-01-16 2018-02-23 Censoring
5 2017-12-16 2018-02-11 Event
6 2018-02-18 2018-03-01 Event
SIMPLE CASE
DATA STRUCTURE
HOW YOU OBSERVE EVENTS
Data do not correspond to the plot.
HEAD OF THE DATA
ID Time Status
1 3 days Event
2 33 days Censoring
3 85 days Event
4 16 days Event
5 24 days Censoring
6 22 days Censoring
Data do correspond to the plot.
SIMPLE CASE
DATA STRUCTURE
HOW YOU HANDLE THEM
KAPLAN-MEIER
TOOLS
ESTIMATES
SURVIVAL CURVES
Log-rank test seeks for statistically
significant differences between curves.
Useful when considering whether
results at a specific time point are
significant due to the sample size.
SURVIVORS
TOOLS
AT A TIME
RISK SET (TABLE)
MODELS
MULTI-STATE
HEAD OF THE DATA
ID Time 1 Event 1 Time 2 Event 2 Time 3 Event 3
1 22 1 995 0 995 0
2 29 1 12 1 422 1
3 1264 0 27 1 1264 0
4 50 1 42 1 84 1
5 22 1 1133 0 114 1
6 33 1 27 1 1427 0
Demonstrational data.
MULTI-STATE CASE
DATA STRUCTURE
USE CASES
COX METHODOLOGY OVERVIEW
1. Proportional hazards
assumptions.
2. Functional form of
continuous variables.
3. Independent observations.
4. Independent censoring
from the mechanism that
rules of event’s times.
5. Non informative censoring
- does not give an
information on parameters of
the time distribution of
events because it does not
depend on them
1 EVENT / COX
PROPORTIONAL HAZARDS
NOTE
One can use accelerated
failure time (AFT) models.
EXAMPLE COEFFICIENTS
variable coef exp(coef)
age 0.15 1.16
ecog.ps 0.10 1.11
rx -0.81 0.44
DIAGNOSTIC PLOTS
Fig. 1: Shoenfeld residuals. Fig. 2: Deviance residuals.
Fig. 3: Martingale residuals.
FUNCTIONS (survminer)
1. ggcoxzph
2. ggcoxdiagnostics
3. ggcoxfunctional
OVARIAN DATA
coxph(Surv(futime, fustat) ~ age + ecog.ps + rx, data=ovarian)
TRANSITION MATRIX
to
from 1 2 3 4 5
1 NA 1 2 NA 3
2 NA NA NA 4 5
3 NA NA NA 6 7
4 NA NA NA NA 8
5 NA NA NA NA NA
N EVENTS (ACYCLIC)
MULTI-STATE MODEL
NA = transition not possible
numbers in cells
=
names of transitions
POSSIBLE TRANSITIONS
The most complicated part is
the proper data coding for the
model’s input.
SOME COEFFICIENTS
transition age=>40 age=20-40 discount=yes gender=female year=2008-2012 year=2013-2017
1 -1.15 -0.77 -0.26 -0.72 0.80 0.94
2 -1.34 -0.72 -0.15 -0.58 0.39 0.31
3 -0.43 -0.04 0.08 -0.53 0.02 -0.11
4 -0.86 -0.66 -0.09 -0.22 0.13 0.23
5 0.14 -0.64 0.14 -0.24 -0.54 -0.63
6 -1.65 -1.23 0.24 -0.35 0.88 1.33
7 -0.82 -0.57 0.39 -0.57 -0.35 0.09
Reference level for
● age - below 20
● year - 2002-2007
N EVENTS (ACYCLIC)
MULTI-STATE MODEL
Depending on the customer
features, the predictions of
being in a state after
particular time are different.
Credits for modeling:
cran.r-project.org/package=
mstate
N EVENTS (ACYCLIC)
MULTI-STATE MODEL
PREDICTIONS OF THE STATE
NOTES
Model assumptions should be considered for every
possible transition.
Time varying variables can be taken into the
account when handling subscription based data.
Playing with cyclic models requires domain
knowledge in (sub) Markov Chain field.
SURVMINER
PLOTS BASED ON
Credits:
cran.r-project.org/package=survminer
github.com/kassambara/survminer
www.ggplot2-exts.org/gallery/
stdha.com/english/rpkgs/survminer
DID YOU LIKE THE TALK? JOIN US AT WHY R? 2020.
24-27 SEPTEMBER
WHYR.PL/2020/
github.com/g6t/mchurn
THANK YOU FOR THE ATTENTION
youtube.com/WhyRFoundation

Contenu connexe

Similaire à Multi state churn analysis with a subscription product

Use of data mining techniques in the discovery of spatial and ...
Use of data mining techniques in the discovery of spatial and ...Use of data mining techniques in the discovery of spatial and ...
Use of data mining techniques in the discovery of spatial and ...butest
 
IRJET - A Framework for Tourist Identification and Analytics using Transport ...
IRJET - A Framework for Tourist Identification and Analytics using Transport ...IRJET - A Framework for Tourist Identification and Analytics using Transport ...
IRJET - A Framework for Tourist Identification and Analytics using Transport ...IRJET Journal
 
IRJET- Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...
IRJET-  	  Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...IRJET-  	  Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...
IRJET- Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...IRJET Journal
 
The Data Science Process
The Data Science ProcessThe Data Science Process
The Data Science ProcessVishal Patel
 
Feature Engineering
Feature Engineering Feature Engineering
Feature Engineering odsc
 
Advanced Econometrics L7-8.pptx
Advanced Econometrics L7-8.pptxAdvanced Econometrics L7-8.pptx
Advanced Econometrics L7-8.pptxakashayosha
 
DIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCY
DIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCYDIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCY
DIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCYIRJET Journal
 
Interpreting the data parallel analysis with sawzall
Interpreting the data  parallel analysis with sawzallInterpreting the data  parallel analysis with sawzall
Interpreting the data parallel analysis with sawzallLee David
 
Bridging data analysis and interactive visualization
Bridging data analysis and interactive visualizationBridging data analysis and interactive visualization
Bridging data analysis and interactive visualizationNacho Caballero
 
Data Provenance for Data Science
Data Provenance for Data ScienceData Provenance for Data Science
Data Provenance for Data SciencePaolo Missier
 
A frame work for clustering time evolving data
A frame work for clustering time evolving dataA frame work for clustering time evolving data
A frame work for clustering time evolving dataiaemedu
 
Preprocessing and secure computations for privacy preservation data mining
Preprocessing and secure computations for privacy preservation data miningPreprocessing and secure computations for privacy preservation data mining
Preprocessing and secure computations for privacy preservation data miningIAEME Publication
 
Learning Accurate Business Process Simulation Models from Event Logs via Auto...
Learning Accurate Business Process Simulation Models from Event Logs via Auto...Learning Accurate Business Process Simulation Models from Event Logs via Auto...
Learning Accurate Business Process Simulation Models from Event Logs via Auto...Marlon Dumas
 
Bitcoin Price Prediction Using LSTM
Bitcoin Price Prediction Using LSTMBitcoin Price Prediction Using LSTM
Bitcoin Price Prediction Using LSTMIRJET Journal
 

Similaire à Multi state churn analysis with a subscription product (20)

RISK EVALUATION-1
RISK EVALUATION-1RISK EVALUATION-1
RISK EVALUATION-1
 
Vivarana literature survey
Vivarana literature surveyVivarana literature survey
Vivarana literature survey
 
presentationIDC - 14MAY2015
presentationIDC - 14MAY2015presentationIDC - 14MAY2015
presentationIDC - 14MAY2015
 
Jobs Complexity
Jobs ComplexityJobs Complexity
Jobs Complexity
 
Use of data mining techniques in the discovery of spatial and ...
Use of data mining techniques in the discovery of spatial and ...Use of data mining techniques in the discovery of spatial and ...
Use of data mining techniques in the discovery of spatial and ...
 
IRJET - A Framework for Tourist Identification and Analytics using Transport ...
IRJET - A Framework for Tourist Identification and Analytics using Transport ...IRJET - A Framework for Tourist Identification and Analytics using Transport ...
IRJET - A Framework for Tourist Identification and Analytics using Transport ...
 
Taller2 parcial2 grupo_4_
Taller2 parcial2 grupo_4_Taller2 parcial2 grupo_4_
Taller2 parcial2 grupo_4_
 
IRJET- Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...
IRJET-  	  Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...IRJET-  	  Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...
IRJET- Improved Model for Big Data Analytics using Dynamic Multi-Swarm Op...
 
The Data Science Process
The Data Science ProcessThe Data Science Process
The Data Science Process
 
Feature Engineering
Feature Engineering Feature Engineering
Feature Engineering
 
Advanced Econometrics L7-8.pptx
Advanced Econometrics L7-8.pptxAdvanced Econometrics L7-8.pptx
Advanced Econometrics L7-8.pptx
 
DIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCY
DIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCYDIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCY
DIGITAL INVESTMENT PREDICTION IN CRYPTOCURRENCY
 
Interpreting the data parallel analysis with sawzall
Interpreting the data  parallel analysis with sawzallInterpreting the data  parallel analysis with sawzall
Interpreting the data parallel analysis with sawzall
 
TYPES OF ANALYTICS.pptx
TYPES OF ANALYTICS.pptxTYPES OF ANALYTICS.pptx
TYPES OF ANALYTICS.pptx
 
Bridging data analysis and interactive visualization
Bridging data analysis and interactive visualizationBridging data analysis and interactive visualization
Bridging data analysis and interactive visualization
 
Data Provenance for Data Science
Data Provenance for Data ScienceData Provenance for Data Science
Data Provenance for Data Science
 
A frame work for clustering time evolving data
A frame work for clustering time evolving dataA frame work for clustering time evolving data
A frame work for clustering time evolving data
 
Preprocessing and secure computations for privacy preservation data mining
Preprocessing and secure computations for privacy preservation data miningPreprocessing and secure computations for privacy preservation data mining
Preprocessing and secure computations for privacy preservation data mining
 
Learning Accurate Business Process Simulation Models from Event Logs via Auto...
Learning Accurate Business Process Simulation Models from Event Logs via Auto...Learning Accurate Business Process Simulation Models from Event Logs via Auto...
Learning Accurate Business Process Simulation Models from Event Logs via Auto...
 
Bitcoin Price Prediction Using LSTM
Bitcoin Price Prediction Using LSTMBitcoin Price Prediction Using LSTM
Bitcoin Price Prediction Using LSTM
 

Plus de Vienna Data Science Group

Liability for machine learning systems by Daniel Deutsch
Liability for machine learning systems by Daniel DeutschLiability for machine learning systems by Daniel Deutsch
Liability for machine learning systems by Daniel DeutschVienna Data Science Group
 
How to get into Kaggle? by Philipp Singer and Dmitry Gordeev
How to get into Kaggle? by Philipp Singer and Dmitry GordeevHow to get into Kaggle? by Philipp Singer and Dmitry Gordeev
How to get into Kaggle? by Philipp Singer and Dmitry GordeevVienna Data Science Group
 
NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...
NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...
NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...Vienna Data Science Group
 
Anita Graser: Analyzing Movment Data with MovingPandas
Anita Graser: Analyzing Movment Data  with MovingPandas Anita Graser: Analyzing Movment Data  with MovingPandas
Anita Graser: Analyzing Movment Data with MovingPandas Vienna Data Science Group
 
Armin Rabitsch's presentation on the importance of social media in the electi...
Armin Rabitsch's presentation on the importance of social media in the electi...Armin Rabitsch's presentation on the importance of social media in the electi...
Armin Rabitsch's presentation on the importance of social media in the electi...Vienna Data Science Group
 
Martina Chichi describes Amnesty International Italy's Barometer of Hate Project
Martina Chichi describes Amnesty International Italy's Barometer of Hate ProjectMartina Chichi describes Amnesty International Italy's Barometer of Hate Project
Martina Chichi describes Amnesty International Italy's Barometer of Hate ProjectVienna Data Science Group
 
Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...
Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...
Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...Vienna Data Science Group
 
Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...
Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...
Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...Vienna Data Science Group
 
Openfabnet - A collaborative approach towards industry 4.0 based on open sour...
Openfabnet - A collaborative approach towards industry 4.0 based on open sour...Openfabnet - A collaborative approach towards industry 4.0 based on open sour...
Openfabnet - A collaborative approach towards industry 4.0 based on open sour...Vienna Data Science Group
 
Lange - Industrial Data Space – Digital Sovereignty over Data
Lange - Industrial Data Space – Digital Sovereignty over DataLange - Industrial Data Space – Digital Sovereignty over Data
Lange - Industrial Data Space – Digital Sovereignty over DataVienna Data Science Group
 
Donner - Deep Learning - Overview and practical aspects
Donner - Deep Learning - Overview and practical aspectsDonner - Deep Learning - Overview and practical aspects
Donner - Deep Learning - Overview and practical aspectsVienna Data Science Group
 
Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...
Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...
Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...Vienna Data Science Group
 
Brunauer, Weidinger - Welcome from the Vienna Data Science Group
Brunauer, Weidinger - Welcome from the Vienna Data Science GroupBrunauer, Weidinger - Welcome from the Vienna Data Science Group
Brunauer, Weidinger - Welcome from the Vienna Data Science GroupVienna Data Science Group
 
Data Market Austria and Data Science Continuing Education Course
Data Market Austria and Data Science Continuing Education CourseData Market Austria and Data Science Continuing Education Course
Data Market Austria and Data Science Continuing Education CourseVienna Data Science Group
 

Plus de Vienna Data Science Group (20)

Deep learning in algorithmic trading
Deep learning in algorithmic tradingDeep learning in algorithmic trading
Deep learning in algorithmic trading
 
Modelling the-spread-of-sars-cov-2
Modelling the-spread-of-sars-cov-2Modelling the-spread-of-sars-cov-2
Modelling the-spread-of-sars-cov-2
 
Deeplearning ai june-sharable (1)
Deeplearning ai june-sharable (1)Deeplearning ai june-sharable (1)
Deeplearning ai june-sharable (1)
 
Liability for machine learning systems by Daniel Deutsch
Liability for machine learning systems by Daniel DeutschLiability for machine learning systems by Daniel Deutsch
Liability for machine learning systems by Daniel Deutsch
 
On data literacy by Marek Danis
On data literacy by Marek Danis On data literacy by Marek Danis
On data literacy by Marek Danis
 
How to get into Kaggle? by Philipp Singer and Dmitry Gordeev
How to get into Kaggle? by Philipp Singer and Dmitry GordeevHow to get into Kaggle? by Philipp Singer and Dmitry Gordeev
How to get into Kaggle? by Philipp Singer and Dmitry Gordeev
 
NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...
NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...
NLP in a Bank: Automated Document Reading: Yevgen Kolesnyk / Patrik Zatko / D...
 
Anita Graser: Analyzing Movment Data with MovingPandas
Anita Graser: Analyzing Movment Data  with MovingPandas Anita Graser: Analyzing Movment Data  with MovingPandas
Anita Graser: Analyzing Movment Data with MovingPandas
 
Armin Rabitsch's presentation on the importance of social media in the electi...
Armin Rabitsch's presentation on the importance of social media in the electi...Armin Rabitsch's presentation on the importance of social media in the electi...
Armin Rabitsch's presentation on the importance of social media in the electi...
 
Martina Chichi describes Amnesty International Italy's Barometer of Hate Project
Martina Chichi describes Amnesty International Italy's Barometer of Hate ProjectMartina Chichi describes Amnesty International Italy's Barometer of Hate Project
Martina Chichi describes Amnesty International Italy's Barometer of Hate Project
 
Vdsg /Craftworks Industrial-AI
Vdsg /Craftworks Industrial-AIVdsg /Craftworks Industrial-AI
Vdsg /Craftworks Industrial-AI
 
Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...
Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...
Roessler, Hafner - Modelling and Simulation in Industrial Applications: Apply...
 
Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...
Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...
Wastian, Brunmeir - Data Analyses in Industrial Applications: From Predictive...
 
Openfabnet - A collaborative approach towards industry 4.0 based on open sour...
Openfabnet - A collaborative approach towards industry 4.0 based on open sour...Openfabnet - A collaborative approach towards industry 4.0 based on open sour...
Openfabnet - A collaborative approach towards industry 4.0 based on open sour...
 
Lange - Industrial Data Space – Digital Sovereignty over Data
Lange - Industrial Data Space – Digital Sovereignty over DataLange - Industrial Data Space – Digital Sovereignty over Data
Lange - Industrial Data Space – Digital Sovereignty over Data
 
Industry 4.0 by VDSG and Informance
Industry 4.0 by VDSG and InformanceIndustry 4.0 by VDSG and Informance
Industry 4.0 by VDSG and Informance
 
Donner - Deep Learning - Overview and practical aspects
Donner - Deep Learning - Overview and practical aspectsDonner - Deep Learning - Overview and practical aspects
Donner - Deep Learning - Overview and practical aspects
 
Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...
Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...
Langs - Machine Learning in Medical Imaging: Learning from Large-scale popula...
 
Brunauer, Weidinger - Welcome from the Vienna Data Science Group
Brunauer, Weidinger - Welcome from the Vienna Data Science GroupBrunauer, Weidinger - Welcome from the Vienna Data Science Group
Brunauer, Weidinger - Welcome from the Vienna Data Science Group
 
Data Market Austria and Data Science Continuing Education Course
Data Market Austria and Data Science Continuing Education CourseData Market Austria and Data Science Continuing Education Course
Data Market Austria and Data Science Continuing Education Course
 

Dernier

Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...nirzagarg
 
Jual Cytotec Asli Obat Aborsi No. 1 Paling Manjur
Jual Cytotec Asli Obat Aborsi No. 1 Paling ManjurJual Cytotec Asli Obat Aborsi No. 1 Paling Manjur
Jual Cytotec Asli Obat Aborsi No. 1 Paling Manjurptikerjasaptiker
 
7. Epi of Chronic respiratory diseases.ppt
7. Epi of Chronic respiratory diseases.ppt7. Epi of Chronic respiratory diseases.ppt
7. Epi of Chronic respiratory diseases.pptibrahimabdi22
 
Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...gajnagarg
 
Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...nirzagarg
 
Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...
Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...
Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...gajnagarg
 
Ranking and Scoring Exercises for Research
Ranking and Scoring Exercises for ResearchRanking and Scoring Exercises for Research
Ranking and Scoring Exercises for ResearchRajesh Mondal
 
SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...
SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...
SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...Elaine Werffeli
 
Data Analyst Tasks to do the internship.pdf
Data Analyst Tasks to do the internship.pdfData Analyst Tasks to do the internship.pdf
Data Analyst Tasks to do the internship.pdftheeltifs
 
Capstone in Interprofessional Informatic // IMPACT OF COVID 19 ON EDUCATION
Capstone in Interprofessional Informatic  // IMPACT OF COVID 19 ON EDUCATIONCapstone in Interprofessional Informatic  // IMPACT OF COVID 19 ON EDUCATION
Capstone in Interprofessional Informatic // IMPACT OF COVID 19 ON EDUCATIONLakpaYanziSherpa
 
Harnessing the Power of GenAI for BI and Reporting.pptx
Harnessing the Power of GenAI for BI and Reporting.pptxHarnessing the Power of GenAI for BI and Reporting.pptx
Harnessing the Power of GenAI for BI and Reporting.pptxParas Gupta
 
怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制
怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制
怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制vexqp
 
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...gajnagarg
 
Dubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls DubaiDubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls Dubaikojalkojal131
 
PLE-statistics document for primary schs
PLE-statistics document for primary schsPLE-statistics document for primary schs
PLE-statistics document for primary schscnajjemba
 
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...nirzagarg
 
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteedamy56318795
 
Lecture_2_Deep_Learning_Overview-newone1
Lecture_2_Deep_Learning_Overview-newone1Lecture_2_Deep_Learning_Overview-newone1
Lecture_2_Deep_Learning_Overview-newone1ranjankumarbehera14
 

Dernier (20)

Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
 
Jual Cytotec Asli Obat Aborsi No. 1 Paling Manjur
Jual Cytotec Asli Obat Aborsi No. 1 Paling ManjurJual Cytotec Asli Obat Aborsi No. 1 Paling Manjur
Jual Cytotec Asli Obat Aborsi No. 1 Paling Manjur
 
7. Epi of Chronic respiratory diseases.ppt
7. Epi of Chronic respiratory diseases.ppt7. Epi of Chronic respiratory diseases.ppt
7. Epi of Chronic respiratory diseases.ppt
 
Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Vadodara [ 7014168258 ] Call Me For Genuine Models ...
 
Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Hapur [ 7014168258 ] Call Me For Genuine Models We ...
 
Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...
Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...
Top profile Call Girls In Chandrapur [ 7014168258 ] Call Me For Genuine Model...
 
Ranking and Scoring Exercises for Research
Ranking and Scoring Exercises for ResearchRanking and Scoring Exercises for Research
Ranking and Scoring Exercises for Research
 
SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...
SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...
SAC 25 Final National, Regional & Local Angel Group Investing Insights 2024 0...
 
Data Analyst Tasks to do the internship.pdf
Data Analyst Tasks to do the internship.pdfData Analyst Tasks to do the internship.pdf
Data Analyst Tasks to do the internship.pdf
 
Capstone in Interprofessional Informatic // IMPACT OF COVID 19 ON EDUCATION
Capstone in Interprofessional Informatic  // IMPACT OF COVID 19 ON EDUCATIONCapstone in Interprofessional Informatic  // IMPACT OF COVID 19 ON EDUCATION
Capstone in Interprofessional Informatic // IMPACT OF COVID 19 ON EDUCATION
 
Harnessing the Power of GenAI for BI and Reporting.pptx
Harnessing the Power of GenAI for BI and Reporting.pptxHarnessing the Power of GenAI for BI and Reporting.pptx
Harnessing the Power of GenAI for BI and Reporting.pptx
 
Sequential and reinforcement learning for demand side management by Margaux B...
Sequential and reinforcement learning for demand side management by Margaux B...Sequential and reinforcement learning for demand side management by Margaux B...
Sequential and reinforcement learning for demand side management by Margaux B...
 
怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制
怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制
怎样办理纽约州立大学宾汉姆顿分校毕业证(SUNY-Bin毕业证书)成绩单学校原版复制
 
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
 
Dubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls DubaiDubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls Dubai
 
PLE-statistics document for primary schs
PLE-statistics document for primary schsPLE-statistics document for primary schs
PLE-statistics document for primary schs
 
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
 
Cytotec in Jeddah+966572737505) get unwanted pregnancy kit Riyadh
Cytotec in Jeddah+966572737505) get unwanted pregnancy kit RiyadhCytotec in Jeddah+966572737505) get unwanted pregnancy kit Riyadh
Cytotec in Jeddah+966572737505) get unwanted pregnancy kit Riyadh
 
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
 
Lecture_2_Deep_Learning_Overview-newone1
Lecture_2_Deep_Learning_Overview-newone1Lecture_2_Deep_Learning_Overview-newone1
Lecture_2_Deep_Learning_Overview-newone1
 

Multi state churn analysis with a subscription product

  • 2. Barcelona Data Science and Machine Learning Meetup Budapest Deep Learning Reading Seminar Budapest Data Science Meetup &
  • 3.
  • 4. Want to give a talk, support or …? joint-meetup@googlegroups.com
  • 5.
  • 8.
  • 9. DEVELOPING INTELLIGENCE POWERED BY DATA MULTI-STATE CHURN ANALYSIS WITH A SUBSCRIPTION PRODUCT
  • 10. WHO IS THIS GUY? MARCIN KOSIŃSKI - WARSAW RUG - R BLOGGER R-ADDICT.COM - WHYR.PL/2020/ MARCIN@GRADIENTMETRICS.COM
  • 11. WE’RE GRADIENT: A crew of quantitative marketers and technologists that gather hard data and build robust statistical models to guide organizations through their most difficult decisions. We’re confirmed data geeks, but word on the street is that we’re easy to work with and pretty fun, too. meet you! Nice to GRADIENTMETRICS.COM
  • 12. A branch of statistics for analyzing the expected duration of time until one or more events happen. Examples 1. A death of the patient. 2. A deactivation of the service. 3. An accident on the road. 4. The device failure. 5. An employee leaving the company. 6. A customer cancelling subscription. TALKING LET'S START SURVIVAL ANALYSIS DEFINITION & EXAMPLES
  • 13. What’s the probability an event will (not) occur after a specific period of time? Which characteristics indicate a reduced or increased risk of occurrence of an event? What periods of time are most (or least) exposed to the risk of an event? ASKING LET'S START SURVIVAL ANALYSIS QUESTIONS IT (MIGHT) ANSWER
  • 14. Data 1. Censoring. 2. Interval data. 3. Observations may not be independent. 4. Time varying features. Events 1. Recurring events - one event might occur multiple times. 2. Competing risks - one of multiple events might occur. 3. A multi-state (cyclic/acyclic) nature of the process. THE SCENARIO DEPENDING ON SURVIVAL ANALYSIS CHALLENGES IT FACES
  • 15. HEAD OF THE DATA ID Start Date End Date Status 1 2018-01-28 2018-02-22 Censoring 2 2017-12-16 2018-01-08 Event 3 2017-12-09 2018-01-06 Censoring 4 2018-01-16 2018-02-23 Censoring 5 2017-12-16 2018-02-11 Event 6 2018-02-18 2018-03-01 Event SIMPLE CASE DATA STRUCTURE HOW YOU OBSERVE EVENTS Data do not correspond to the plot.
  • 16. HEAD OF THE DATA ID Time Status 1 3 days Event 2 33 days Censoring 3 85 days Event 4 16 days Event 5 24 days Censoring 6 22 days Censoring Data do correspond to the plot. SIMPLE CASE DATA STRUCTURE HOW YOU HANDLE THEM
  • 17. KAPLAN-MEIER TOOLS ESTIMATES SURVIVAL CURVES Log-rank test seeks for statistically significant differences between curves.
  • 18. Useful when considering whether results at a specific time point are significant due to the sample size. SURVIVORS TOOLS AT A TIME RISK SET (TABLE)
  • 20. HEAD OF THE DATA ID Time 1 Event 1 Time 2 Event 2 Time 3 Event 3 1 22 1 995 0 995 0 2 29 1 12 1 422 1 3 1264 0 27 1 1264 0 4 50 1 42 1 84 1 5 22 1 1133 0 114 1 6 33 1 27 1 1427 0 Demonstrational data. MULTI-STATE CASE DATA STRUCTURE
  • 22. COX METHODOLOGY OVERVIEW 1. Proportional hazards assumptions. 2. Functional form of continuous variables. 3. Independent observations. 4. Independent censoring from the mechanism that rules of event’s times. 5. Non informative censoring - does not give an information on parameters of the time distribution of events because it does not depend on them 1 EVENT / COX PROPORTIONAL HAZARDS NOTE One can use accelerated failure time (AFT) models. EXAMPLE COEFFICIENTS variable coef exp(coef) age 0.15 1.16 ecog.ps 0.10 1.11 rx -0.81 0.44 DIAGNOSTIC PLOTS Fig. 1: Shoenfeld residuals. Fig. 2: Deviance residuals. Fig. 3: Martingale residuals. FUNCTIONS (survminer) 1. ggcoxzph 2. ggcoxdiagnostics 3. ggcoxfunctional OVARIAN DATA coxph(Surv(futime, fustat) ~ age + ecog.ps + rx, data=ovarian)
  • 23. TRANSITION MATRIX to from 1 2 3 4 5 1 NA 1 2 NA 3 2 NA NA NA 4 5 3 NA NA NA 6 7 4 NA NA NA NA 8 5 NA NA NA NA NA N EVENTS (ACYCLIC) MULTI-STATE MODEL NA = transition not possible numbers in cells = names of transitions POSSIBLE TRANSITIONS The most complicated part is the proper data coding for the model’s input.
  • 24. SOME COEFFICIENTS transition age=>40 age=20-40 discount=yes gender=female year=2008-2012 year=2013-2017 1 -1.15 -0.77 -0.26 -0.72 0.80 0.94 2 -1.34 -0.72 -0.15 -0.58 0.39 0.31 3 -0.43 -0.04 0.08 -0.53 0.02 -0.11 4 -0.86 -0.66 -0.09 -0.22 0.13 0.23 5 0.14 -0.64 0.14 -0.24 -0.54 -0.63 6 -1.65 -1.23 0.24 -0.35 0.88 1.33 7 -0.82 -0.57 0.39 -0.57 -0.35 0.09 Reference level for ● age - below 20 ● year - 2002-2007 N EVENTS (ACYCLIC) MULTI-STATE MODEL
  • 25. Depending on the customer features, the predictions of being in a state after particular time are different. Credits for modeling: cran.r-project.org/package= mstate N EVENTS (ACYCLIC) MULTI-STATE MODEL PREDICTIONS OF THE STATE
  • 26. NOTES
  • 27. Model assumptions should be considered for every possible transition. Time varying variables can be taken into the account when handling subscription based data. Playing with cyclic models requires domain knowledge in (sub) Markov Chain field.
  • 29. DID YOU LIKE THE TALK? JOIN US AT WHY R? 2020. 24-27 SEPTEMBER WHYR.PL/2020/ github.com/g6t/mchurn THANK YOU FOR THE ATTENTION youtube.com/WhyRFoundation