SlideShare uma empresa Scribd logo
1 de 23
Baixar para ler offline
Correlation

 FF2613
Correlation

• 2 Continuous Variables
     • linear relationship


• analysis of the relationship between two
  quantitative outcomes, e.g., height and
  weight.
Bivariate Correlation




Positive and Linear   Negative and Linear
How to calculate r?
                              a




b                         c
Example


•∑ x = 4631          ∑ x2 = 688837
•∑ y = 2863          ∑ y2 = 264527
•∑ xy = 424780        n = 32

•a=424780-(4631*2863/32)=10,450.22
•b=688837-46312/32=18,644.47
•c=264527-28632/32=8,377.969
•r=a/(b*c)0.5
  =10,450.22/(18,644.47*83,77.969)0.5
  =0.836144


•t= 0.836144*((32-2)/(1-0.8361442))0.5
t = 8.349436 & d.f. = n - 2 = 30,
p < 0.001
Please refer to Table A3.
        We use df = 30.
 t = 8.3494 > 3.65 (p=0.001)

Therefore if t=8.3494, p<0.001.
How to interpret the value of r?
• r lies between -1 and 1. Values near 0
  means no (linear) correlation and values
  near ± 1 means very strong correlation.
• The negative sign means that the two
  variables are inversely related, that is, as
  one variable increases the other variable
  decreases.
How to interpret the value of r?
Pearson’s r
• A 0.9 is a strong positive association (as one
  variable rises, so does the other)
• A -0.9 is a strong negative association
  (as one variable rises, the other falls)



  r=0.9 has nothing to do with 90%
  r=correlation coefficient
Coefficient of Determination
             Defined
• Pearson’s r can be squared , r 2, to derive
  a coefficient of determination.


• Coefficient of determination – the portion
  of variability in one of the variables that
  can be accounted for by variability in the
  second variable
Coefficient of
   Determination
• Pearson’s r can be squared , r 2, to derive a
  coefficient of determination.

• Example of depression and CGPA
  – Pearson’s r shows negative correlation, r=-0.5
  – r2=0.25

  – In this example we can say that 1/4 or 0.25 of the
    variability in CGPA scores can be accounted for by
    depression (remaining 75% of variability is other
    factors, habits, ability, motivation, courses studied,
    etc)
Coefficient of Determination
         and Pearson’s r
• Pearson’s r can be squared , r 2

• If r=0.5, then r2=0.25
• If r=0.7 then r2=0.49

• Thus while r=0.5 versus 0.7 might not look so
  different in terms of strength, r2 tells us that
  r=0.7 accounts for about twice the variability
  relative to r=0.5
Causal Silence:
Correlation Does Not Imply
Causality


     Causality – must demonstrate that variance
      in one variable can only be due to
      influence of the other variable

     • Directionality of Effect Problem


     • Third Variable Problem
Correlation In SPSS

• For this exercise, we will
  be using the data from
  the CD, under Chapter 8,
  korelasi.sav
• This data is a subset of a
  case-control study on
  factors affecting SGA in
  Kelantan.
• Open the data & select -
  >Analyse
     >Correlate
        >Bivariate…
Correlation in SPSS
• We want to see whether
  there is any association
  between the mothers’
  weight and the
  babies’weight. So select
  the variables (weight2 &
  birthwgt) into ‘Variables’.
• Select ‘Pearson’
  Correlation Coefficients.
• Click the ‘OK’ button.
Correlations

         Correlation Results
         WEIGHT2        Pearson Correlation
                                                  WEIGHT2 BIRTHWGT
                                                         1     .431*
                        Sig. (2-tailed)                  .     .017
                        N                               30       30
         BIRTHWGT       Pearson Correlation           .431*       1
                        Sig. (2-tailed)               .017        .
                        N                               30       30
           *. Correlation is significant at the 0.05 level (2-tailed).




• The r = 0.431 and the p value is significant
  at 0.017.
• The r value indicates a fair and positive
  linear relationship.
Scatter Diagram

              3.6
              3.4
              3.2
                                                                           • If the correlation is
              3.0                                                            significant, it is best
              2.8
              2.6
                                                                             to include the
              2.4                                                            scatter diagram.
              2.2
              2.0                                                          • The r square
              1.8
              1.6                                                            indicated mothers’
              1.4                                                            weight contribute
              1.2
                                                                             19% of the
BIRTHWEIGHT




              1.0
               .8
               .6
                                                                             variability of the
               .4                                                            babies’ weight.
               .2
              0.0                                                          Rsq = 0.1861
                    0   10   20   30   40   50   60   70   80   90   100


                    MOTHERS' WEIGHT
Linear Regression
Linear Regression
 • Come up with a Linear Regression Model to
   predict a continuous outcome with a
   continuous risk factor, i.e. predict BP with age.
   Usually the next step after correlation is found
   to be strongly significant.
 • y = a + bx
    – e.g. BP = constant (a) + regression coefficient (b) * age

 • b=
Regression Line
• In a scatterplot showing the association
  between 2 variables, the regression line is
  the “best-fit” line and has the formula
y=a + bx
a=place where line crosses Y axis
b=slope of line (rise/run)
Thus, given a value of X, we can predict a
  value of Y
Regression Line
               (Defined)
Regression line is the line where absolute values
 of vertical distances between points on
 scatterplot and a line form a minimum sum
 (relative to other possible lines)




      Positive and Linear Negative and Linear
Example

      b=

∑x = 6426          ∑ x2 = 1338088
∑y = 4631          ∑ xy = 929701
n = 32
b = (929701-(6426*4631/32))/
(1338088-(64262/32)) = -0.00549
Mean x = 6426/32=200.8125
mean y = 4631/32=144.71875
y = a + bx
a = y – bx (replace the x, y & b value)
a = 144.71875+(0.00549*200.8125)
= 145.8212106
Systolic BP = 144.71875 - 0.00549.chol

Mais conteúdo relacionado

Mais procurados

Correlation and regression
Correlation and regressionCorrelation and regression
Correlation and regressionMohit Asija
 
Linear regression and correlation analysis ppt @ bec doms
Linear regression and correlation analysis ppt @ bec domsLinear regression and correlation analysis ppt @ bec doms
Linear regression and correlation analysis ppt @ bec domsBabasab Patil
 
Karl pearson's correlation
Karl pearson's correlationKarl pearson's correlation
Karl pearson's correlationfairoos1
 
Statistics-Correlation and Regression Analysis
Statistics-Correlation and Regression AnalysisStatistics-Correlation and Regression Analysis
Statistics-Correlation and Regression AnalysisRabin BK
 
Correlation and regression
Correlation and regressionCorrelation and regression
Correlation and regressionAbdelaziz Tayoun
 
Correlation & Regression
Correlation & RegressionCorrelation & Regression
Correlation & RegressionGrant Heller
 
Karl pearson's coefficient of correlation (1)
Karl pearson's coefficient of correlation (1)Karl pearson's coefficient of correlation (1)
Karl pearson's coefficient of correlation (1)teenathankachen1993
 
Correlation and Regression Analysis using SPSS and Microsoft Excel
Correlation and Regression Analysis using SPSS and Microsoft ExcelCorrelation and Regression Analysis using SPSS and Microsoft Excel
Correlation and Regression Analysis using SPSS and Microsoft ExcelSetia Pramana
 
Correlation and Regression ppt
Correlation and Regression pptCorrelation and Regression ppt
Correlation and Regression pptSantosh Bhaskar
 

Mais procurados (19)

Correlation and regression
Correlation and regressionCorrelation and regression
Correlation and regression
 
Correlation 2
Correlation 2Correlation 2
Correlation 2
 
Linear regression and correlation analysis ppt @ bec doms
Linear regression and correlation analysis ppt @ bec domsLinear regression and correlation analysis ppt @ bec doms
Linear regression and correlation analysis ppt @ bec doms
 
Karl pearson's correlation
Karl pearson's correlationKarl pearson's correlation
Karl pearson's correlation
 
Correlation
CorrelationCorrelation
Correlation
 
Correlation
CorrelationCorrelation
Correlation
 
Statistics-Correlation and Regression Analysis
Statistics-Correlation and Regression AnalysisStatistics-Correlation and Regression Analysis
Statistics-Correlation and Regression Analysis
 
Correlation and regression
Correlation and regressionCorrelation and regression
Correlation and regression
 
Statistical technique exercise 23 and 24 correlational study
Statistical technique exercise 23 and 24 correlational studyStatistical technique exercise 23 and 24 correlational study
Statistical technique exercise 23 and 24 correlational study
 
Correlation
CorrelationCorrelation
Correlation
 
Correlation and Regression
Correlation and RegressionCorrelation and Regression
Correlation and Regression
 
Correlation & Regression
Correlation & RegressionCorrelation & Regression
Correlation & Regression
 
Correlation
CorrelationCorrelation
Correlation
 
Karl pearson's coefficient of correlation (1)
Karl pearson's coefficient of correlation (1)Karl pearson's coefficient of correlation (1)
Karl pearson's coefficient of correlation (1)
 
Correlation and Regression Analysis using SPSS and Microsoft Excel
Correlation and Regression Analysis using SPSS and Microsoft ExcelCorrelation and Regression Analysis using SPSS and Microsoft Excel
Correlation and Regression Analysis using SPSS and Microsoft Excel
 
Correlation and Regression ppt
Correlation and Regression pptCorrelation and Regression ppt
Correlation and Regression ppt
 
correlation
correlation correlation
correlation
 
Correlation and Regression
Correlation and Regression Correlation and Regression
Correlation and Regression
 
Correlation
CorrelationCorrelation
Correlation
 

Semelhante a Correlation & Linear Regression

Correlation and regression
Correlation and regressionCorrelation and regression
Correlation and regressionANCYBS
 
Correlation and Regression Analysis.pptx
Correlation and Regression Analysis.pptxCorrelation and Regression Analysis.pptx
Correlation and Regression Analysis.pptxUnfold1
 
Regression and Co-Relation
Regression and Co-RelationRegression and Co-Relation
Regression and Co-Relationnuwan udugampala
 
Correlation and Regression Analysis.pptx
Correlation and Regression Analysis.pptxCorrelation and Regression Analysis.pptx
Correlation and Regression Analysis.pptxasemzkgmu
 
Biostatistics lecture notes 7.ppt
Biostatistics lecture notes 7.pptBiostatistics lecture notes 7.ppt
Biostatistics lecture notes 7.pptletayh2016
 
Class 9 Covariance & Correlation Concepts.pptx
Class 9 Covariance & Correlation Concepts.pptxClass 9 Covariance & Correlation Concepts.pptx
Class 9 Covariance & Correlation Concepts.pptxCallplanetsDeveloper
 
CORRELATION ( srm1) - Copy.pptx
CORRELATION ( srm1) - Copy.pptxCORRELATION ( srm1) - Copy.pptx
CORRELATION ( srm1) - Copy.pptxVaishnaviElumalai
 
Correlation Statistics
Correlation StatisticsCorrelation Statistics
Correlation Statisticstahmid rashid
 
Topic 5 Covariance & Correlation.pptx
Topic 5  Covariance & Correlation.pptxTopic 5  Covariance & Correlation.pptx
Topic 5 Covariance & Correlation.pptxCallplanetsDeveloper
 
Topic 5 Covariance & Correlation.pptx
Topic 5  Covariance & Correlation.pptxTopic 5  Covariance & Correlation.pptx
Topic 5 Covariance & Correlation.pptxCallplanetsDeveloper
 
Case study on One way ANOVA
Case study on One way ANOVACase study on One way ANOVA
Case study on One way ANOVANadzirah Hanis
 

Semelhante a Correlation & Linear Regression (20)

Correlation and regression
Correlation and regressionCorrelation and regression
Correlation and regression
 
Correlations
CorrelationsCorrelations
Correlations
 
Correlation and Regression Analysis.pptx
Correlation and Regression Analysis.pptxCorrelation and Regression Analysis.pptx
Correlation and Regression Analysis.pptx
 
Regression and Co-Relation
Regression and Co-RelationRegression and Co-Relation
Regression and Co-Relation
 
Correlation and Regression Analysis.pptx
Correlation and Regression Analysis.pptxCorrelation and Regression Analysis.pptx
Correlation and Regression Analysis.pptx
 
Regression
RegressionRegression
Regression
 
13943056.ppt
13943056.ppt13943056.ppt
13943056.ppt
 
Biostatistics lecture notes 7.ppt
Biostatistics lecture notes 7.pptBiostatistics lecture notes 7.ppt
Biostatistics lecture notes 7.ppt
 
correlation ;.pptx
correlation ;.pptxcorrelation ;.pptx
correlation ;.pptx
 
correlation.pptx
correlation.pptxcorrelation.pptx
correlation.pptx
 
Correlation continued
Correlation continuedCorrelation continued
Correlation continued
 
Class 9 Covariance & Correlation Concepts.pptx
Class 9 Covariance & Correlation Concepts.pptxClass 9 Covariance & Correlation Concepts.pptx
Class 9 Covariance & Correlation Concepts.pptx
 
correlation.ppt
correlation.pptcorrelation.ppt
correlation.ppt
 
12943625.ppt
12943625.ppt12943625.ppt
12943625.ppt
 
CORRELATION ( srm1) - Copy.pptx
CORRELATION ( srm1) - Copy.pptxCORRELATION ( srm1) - Copy.pptx
CORRELATION ( srm1) - Copy.pptx
 
Correlation Statistics
Correlation StatisticsCorrelation Statistics
Correlation Statistics
 
Topic 5 Covariance & Correlation.pptx
Topic 5  Covariance & Correlation.pptxTopic 5  Covariance & Correlation.pptx
Topic 5 Covariance & Correlation.pptx
 
Topic 5 Covariance & Correlation.pptx
Topic 5  Covariance & Correlation.pptxTopic 5  Covariance & Correlation.pptx
Topic 5 Covariance & Correlation.pptx
 
Case study on One way ANOVA
Case study on One way ANOVACase study on One way ANOVA
Case study on One way ANOVA
 
Corr And Regress
Corr And RegressCorr And Regress
Corr And Regress
 

Mais de Azmi Mohd Tamil

Hybrid setup - How to conduct simultaneous face-to-face and online presentati...
Hybrid setup - How to conduct simultaneous face-to-face and online presentati...Hybrid setup - How to conduct simultaneous face-to-face and online presentati...
Hybrid setup - How to conduct simultaneous face-to-face and online presentati...Azmi Mohd Tamil
 
Audiovisual and technicalities from preparation to retrieval how to enhance m...
Audiovisual and technicalities from preparation to retrieval how to enhance m...Audiovisual and technicalities from preparation to retrieval how to enhance m...
Audiovisual and technicalities from preparation to retrieval how to enhance m...Azmi Mohd Tamil
 
Broadcast quality online teaching at zero budget
Broadcast quality online teaching at zero budgetBroadcast quality online teaching at zero budget
Broadcast quality online teaching at zero budgetAzmi Mohd Tamil
 
Video for Teaching & Learning: OBS
Video for Teaching & Learning: OBSVideo for Teaching & Learning: OBS
Video for Teaching & Learning: OBSAzmi Mohd Tamil
 
Bengkel 21-12-2020 - Etika atas Talian & Alat Minima
Bengkel 21-12-2020 - Etika atas Talian & Alat MinimaBengkel 21-12-2020 - Etika atas Talian & Alat Minima
Bengkel 21-12-2020 - Etika atas Talian & Alat MinimaAzmi Mohd Tamil
 
GIS & History of Mapping in Malaya (lecture notes circa 2009)
GIS & History of Mapping in Malaya (lecture notes circa 2009)GIS & History of Mapping in Malaya (lecture notes circa 2009)
GIS & History of Mapping in Malaya (lecture notes circa 2009)Azmi Mohd Tamil
 
Blended e-learning in UKMFolio
Blended e-learning in UKMFolioBlended e-learning in UKMFolio
Blended e-learning in UKMFolioAzmi Mohd Tamil
 
How to Compute & Recode SPSS Data
How to Compute & Recode SPSS DataHow to Compute & Recode SPSS Data
How to Compute & Recode SPSS DataAzmi Mohd Tamil
 
Introduction to Data Analysis With R and R Studio
Introduction to Data Analysis With R and R StudioIntroduction to Data Analysis With R and R Studio
Introduction to Data Analysis With R and R StudioAzmi Mohd Tamil
 
Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...
Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...
Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...Azmi Mohd Tamil
 
Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...
Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...
Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...Azmi Mohd Tamil
 
Cochran Mantel Haenszel Test with Breslow-Day Test & Quadratic Equation
Cochran Mantel Haenszel Test with Breslow-Day Test & Quadratic EquationCochran Mantel Haenszel Test with Breslow-Day Test & Quadratic Equation
Cochran Mantel Haenszel Test with Breslow-Day Test & Quadratic EquationAzmi Mohd Tamil
 
New Emerging And Reemerging Infections circa 2006
New Emerging And Reemerging Infections circa 2006New Emerging And Reemerging Infections circa 2006
New Emerging And Reemerging Infections circa 2006Azmi Mohd Tamil
 
Hacks#36 -Raspberry Pi 4 Mini Computer
Hacks#36 -Raspberry Pi 4 Mini ComputerHacks#36 -Raspberry Pi 4 Mini Computer
Hacks#36 -Raspberry Pi 4 Mini ComputerAzmi Mohd Tamil
 
Hack#35 How to FB Live using a Video Encoder
Hack#35 How to FB Live using a Video EncoderHack#35 How to FB Live using a Video Encoder
Hack#35 How to FB Live using a Video EncoderAzmi Mohd Tamil
 
Hack#34 - Online Teaching with Microsoft Teams
Hack#34 - Online Teaching with Microsoft TeamsHack#34 - Online Teaching with Microsoft Teams
Hack#34 - Online Teaching with Microsoft TeamsAzmi Mohd Tamil
 
Skype for Business for UKM
Skype for Business for UKM Skype for Business for UKM
Skype for Business for UKM Azmi Mohd Tamil
 
Introduction to Structural Equation Modeling
Introduction to Structural Equation ModelingIntroduction to Structural Equation Modeling
Introduction to Structural Equation ModelingAzmi Mohd Tamil
 
Safe computing (circa 2004)
Safe computing (circa 2004)Safe computing (circa 2004)
Safe computing (circa 2004)Azmi Mohd Tamil
 

Mais de Azmi Mohd Tamil (20)

Hybrid setup - How to conduct simultaneous face-to-face and online presentati...
Hybrid setup - How to conduct simultaneous face-to-face and online presentati...Hybrid setup - How to conduct simultaneous face-to-face and online presentati...
Hybrid setup - How to conduct simultaneous face-to-face and online presentati...
 
Audiovisual and technicalities from preparation to retrieval how to enhance m...
Audiovisual and technicalities from preparation to retrieval how to enhance m...Audiovisual and technicalities from preparation to retrieval how to enhance m...
Audiovisual and technicalities from preparation to retrieval how to enhance m...
 
Broadcast quality online teaching at zero budget
Broadcast quality online teaching at zero budgetBroadcast quality online teaching at zero budget
Broadcast quality online teaching at zero budget
 
Video for Teaching & Learning: OBS
Video for Teaching & Learning: OBSVideo for Teaching & Learning: OBS
Video for Teaching & Learning: OBS
 
Bengkel 21-12-2020 - Etika atas Talian & Alat Minima
Bengkel 21-12-2020 - Etika atas Talian & Alat MinimaBengkel 21-12-2020 - Etika atas Talian & Alat Minima
Bengkel 21-12-2020 - Etika atas Talian & Alat Minima
 
GIS & History of Mapping in Malaya (lecture notes circa 2009)
GIS & History of Mapping in Malaya (lecture notes circa 2009)GIS & History of Mapping in Malaya (lecture notes circa 2009)
GIS & History of Mapping in Malaya (lecture notes circa 2009)
 
Blended e-learning in UKMFolio
Blended e-learning in UKMFolioBlended e-learning in UKMFolio
Blended e-learning in UKMFolio
 
How to Compute & Recode SPSS Data
How to Compute & Recode SPSS DataHow to Compute & Recode SPSS Data
How to Compute & Recode SPSS Data
 
Introduction to Data Analysis With R and R Studio
Introduction to Data Analysis With R and R StudioIntroduction to Data Analysis With R and R Studio
Introduction to Data Analysis With R and R Studio
 
Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...
Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...
Hack#38 - How to Stream Zoom to Facebook & YouTube Without Using An Encoder o...
 
Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...
Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...
Hack#37 - How to simultaneously live stream to 4 sites using a single hardwar...
 
Cochran Mantel Haenszel Test with Breslow-Day Test & Quadratic Equation
Cochran Mantel Haenszel Test with Breslow-Day Test & Quadratic EquationCochran Mantel Haenszel Test with Breslow-Day Test & Quadratic Equation
Cochran Mantel Haenszel Test with Breslow-Day Test & Quadratic Equation
 
New Emerging And Reemerging Infections circa 2006
New Emerging And Reemerging Infections circa 2006New Emerging And Reemerging Infections circa 2006
New Emerging And Reemerging Infections circa 2006
 
Hacks#36 -Raspberry Pi 4 Mini Computer
Hacks#36 -Raspberry Pi 4 Mini ComputerHacks#36 -Raspberry Pi 4 Mini Computer
Hacks#36 -Raspberry Pi 4 Mini Computer
 
Hack#35 How to FB Live using a Video Encoder
Hack#35 How to FB Live using a Video EncoderHack#35 How to FB Live using a Video Encoder
Hack#35 How to FB Live using a Video Encoder
 
Hack#34 - Online Teaching with Microsoft Teams
Hack#34 - Online Teaching with Microsoft TeamsHack#34 - Online Teaching with Microsoft Teams
Hack#34 - Online Teaching with Microsoft Teams
 
Hack#33 How To FB-Live
Hack#33 How To FB-LiveHack#33 How To FB-Live
Hack#33 How To FB-Live
 
Skype for Business for UKM
Skype for Business for UKM Skype for Business for UKM
Skype for Business for UKM
 
Introduction to Structural Equation Modeling
Introduction to Structural Equation ModelingIntroduction to Structural Equation Modeling
Introduction to Structural Equation Modeling
 
Safe computing (circa 2004)
Safe computing (circa 2004)Safe computing (circa 2004)
Safe computing (circa 2004)
 

Último

Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbuapidays
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 

Último (20)

Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 

Correlation & Linear Regression

  • 2. Correlation • 2 Continuous Variables • linear relationship • analysis of the relationship between two quantitative outcomes, e.g., height and weight.
  • 3.
  • 4. Bivariate Correlation Positive and Linear Negative and Linear
  • 5. How to calculate r? a b c
  • 6. Example •∑ x = 4631 ∑ x2 = 688837 •∑ y = 2863 ∑ y2 = 264527 •∑ xy = 424780 n = 32 •a=424780-(4631*2863/32)=10,450.22 •b=688837-46312/32=18,644.47 •c=264527-28632/32=8,377.969 •r=a/(b*c)0.5 =10,450.22/(18,644.47*83,77.969)0.5 =0.836144 •t= 0.836144*((32-2)/(1-0.8361442))0.5 t = 8.349436 & d.f. = n - 2 = 30, p < 0.001
  • 7. Please refer to Table A3. We use df = 30. t = 8.3494 > 3.65 (p=0.001) Therefore if t=8.3494, p<0.001.
  • 8. How to interpret the value of r? • r lies between -1 and 1. Values near 0 means no (linear) correlation and values near ± 1 means very strong correlation. • The negative sign means that the two variables are inversely related, that is, as one variable increases the other variable decreases.
  • 9. How to interpret the value of r?
  • 10. Pearson’s r • A 0.9 is a strong positive association (as one variable rises, so does the other) • A -0.9 is a strong negative association (as one variable rises, the other falls) r=0.9 has nothing to do with 90% r=correlation coefficient
  • 11. Coefficient of Determination Defined • Pearson’s r can be squared , r 2, to derive a coefficient of determination. • Coefficient of determination – the portion of variability in one of the variables that can be accounted for by variability in the second variable
  • 12. Coefficient of Determination • Pearson’s r can be squared , r 2, to derive a coefficient of determination. • Example of depression and CGPA – Pearson’s r shows negative correlation, r=-0.5 – r2=0.25 – In this example we can say that 1/4 or 0.25 of the variability in CGPA scores can be accounted for by depression (remaining 75% of variability is other factors, habits, ability, motivation, courses studied, etc)
  • 13. Coefficient of Determination and Pearson’s r • Pearson’s r can be squared , r 2 • If r=0.5, then r2=0.25 • If r=0.7 then r2=0.49 • Thus while r=0.5 versus 0.7 might not look so different in terms of strength, r2 tells us that r=0.7 accounts for about twice the variability relative to r=0.5
  • 14. Causal Silence: Correlation Does Not Imply Causality Causality – must demonstrate that variance in one variable can only be due to influence of the other variable • Directionality of Effect Problem • Third Variable Problem
  • 15. Correlation In SPSS • For this exercise, we will be using the data from the CD, under Chapter 8, korelasi.sav • This data is a subset of a case-control study on factors affecting SGA in Kelantan. • Open the data & select - >Analyse >Correlate >Bivariate…
  • 16. Correlation in SPSS • We want to see whether there is any association between the mothers’ weight and the babies’weight. So select the variables (weight2 & birthwgt) into ‘Variables’. • Select ‘Pearson’ Correlation Coefficients. • Click the ‘OK’ button.
  • 17. Correlations Correlation Results WEIGHT2 Pearson Correlation WEIGHT2 BIRTHWGT 1 .431* Sig. (2-tailed) . .017 N 30 30 BIRTHWGT Pearson Correlation .431* 1 Sig. (2-tailed) .017 . N 30 30 *. Correlation is significant at the 0.05 level (2-tailed). • The r = 0.431 and the p value is significant at 0.017. • The r value indicates a fair and positive linear relationship.
  • 18. Scatter Diagram 3.6 3.4 3.2 • If the correlation is 3.0 significant, it is best 2.8 2.6 to include the 2.4 scatter diagram. 2.2 2.0 • The r square 1.8 1.6 indicated mothers’ 1.4 weight contribute 1.2 19% of the BIRTHWEIGHT 1.0 .8 .6 variability of the .4 babies’ weight. .2 0.0 Rsq = 0.1861 0 10 20 30 40 50 60 70 80 90 100 MOTHERS' WEIGHT
  • 20. Linear Regression • Come up with a Linear Regression Model to predict a continuous outcome with a continuous risk factor, i.e. predict BP with age. Usually the next step after correlation is found to be strongly significant. • y = a + bx – e.g. BP = constant (a) + regression coefficient (b) * age • b=
  • 21. Regression Line • In a scatterplot showing the association between 2 variables, the regression line is the “best-fit” line and has the formula y=a + bx a=place where line crosses Y axis b=slope of line (rise/run) Thus, given a value of X, we can predict a value of Y
  • 22. Regression Line (Defined) Regression line is the line where absolute values of vertical distances between points on scatterplot and a line form a minimum sum (relative to other possible lines) Positive and Linear Negative and Linear
  • 23. Example b= ∑x = 6426 ∑ x2 = 1338088 ∑y = 4631 ∑ xy = 929701 n = 32 b = (929701-(6426*4631/32))/ (1338088-(64262/32)) = -0.00549 Mean x = 6426/32=200.8125 mean y = 4631/32=144.71875 y = a + bx a = y – bx (replace the x, y & b value) a = 144.71875+(0.00549*200.8125) = 145.8212106 Systolic BP = 144.71875 - 0.00549.chol