Difference between revisions of "Manuals/calci/RSQ"

From ZCubes Wiki
Jump to navigation Jump to search
 
(17 intermediate revisions by 4 users not shown)
Line 1: Line 1:
<div style="font-size:30px">'''RSQ(ar1,ar2)'''</div><br/>
+
<div style="font-size:30px">'''RSQ (Array1,Array2)'''</div><br/>
*<math>ar1</math>  is the array of y values .
+
*<math>Array1</math>  is the array of y values.
*<math>ar2</math>  is the array of x values.
+
*<math>Array2</math>  is the array of x values.
 +
**RSQ(), returns the square of the Pearson product moment correlation coefficient.
  
  
Line 7: Line 8:
 
*This function gives the square of Pearson Product Moment Correlation Coefficient.  
 
*This function gives the square of Pearson Product Moment Correlation Coefficient.  
 
*This function is calculated using the data points of <math>y</math> and <math>x</math> values.  
 
*This function is calculated using the data points of <math>y</math> and <math>x</math> values.  
*The formula for PPMC,<math>r</math> is defined by:
+
*The formula for PPMC, <math>r</math> is defined by:
 
<math> r= \frac{ \Sigma(x-\bar{x})(y-\bar{y})}{\sqrt {\Sigma(x-\bar{x})^2(y-\bar{y})^2}}</math>     
 
<math> r= \frac{ \Sigma(x-\bar{x})(y-\bar{y})}{\sqrt {\Sigma(x-\bar{x})^2(y-\bar{y})^2}}</math>     
 
where <math> \bar{x}</math>  and  <math>\bar{y} </math>  are Average of the two Samples <math>x </math> and  <math>y </math>.   
 
where <math> \bar{x}</math>  and  <math>\bar{y} </math>  are Average of the two Samples <math>x </math> and  <math>y </math>.   
*This function gives the value of <math> r^2</math>, which is the square of this correlation coefficient.   
+
*This function gives the value of <math> r^2</math>, which is the square of this Correlation Coefficient.   
*The square value can be interpreted as the proportion of the variance in y attributable to the variance in x.  
+
*The square value can be interpreted as the proportion of the variance in <math>y</math> attributable to the variance in <math>x</math>.  
*In <math> RSQ(ar1,ar2)</math>,the value of <math>ar1</math> and <math>ar1</math> must be either numbers or names, array,constants or references that contain numbers.  
+
*In <math> RSQ(Array1,Array2)</math>, the value of <math>Array1</math> and <math>Array2</math> must be either numbers or names, array, constants or references that contain numbers.  
*Suppose the array contains text,logicl values or empty cells, like that values are not considered.   
+
*Suppose the array contains text, logicl values or empty cells, like that values are not considered.   
*This function will return the result as error when 1. ar1 and ar2 are empty or having the different number of data points.
+
*This function will return the result as error when
2. The arguments having only one data point.
+
1. <math>Array1</math> and <math>Array2</math> are empty or having the different number of data points.
3. The arguments that are error values or text that cannot be translated in to numbers.
+
2. The arguments having only one data point.
We want to know more detail, see PEARSON.
+
3. The arguments that are error values or text that cannot be translated in to numbers.
 +
Refer [[Manuals/calci/PEARSON |PEARSON]] for more details.
  
 
==Examples==
 
==Examples==
Line 32: Line 34:
 
|-
 
|-
 
! 3
 
! 3
| 9 ||
+
| 9 || 7 || 23 || 11 || 22 || 30 ||  6 || 15
 +
|-
 +
! 4
 +
| 50 || 47 || 26 || 13 || 20 || 14 || 33 || 1
 +
|-
 +
! 5
 +
| 4 || 17 || 25 || 44 || 2 || 9 || -1 ||
 +
|-
 +
! 6
 +
| 18 || 36 || 40 || 11 || || || ||
 +
|}
 +
 
 +
# =RSQ(A1:A6,B1:B6) = 0.4003286578
 +
# =RSQ(C1:C6,D1:D6) = 0.02320694105
 +
# =RSQ(E1:H1,E2:H2) = 0.72060025461
 +
# =RSQ(E3:E5,G3:G5) = 0.346037364910
 +
# =RSQ(G3:G5,H3:H4) = NAN
 +
 
 +
==Related Videos==
 +
 
 +
{{#ev:youtube|anebTt-Jbqs|280|center|RSQ}}
 +
 
 +
==See Also==
 +
[[Manuals/calci/PEARSON |PEARSON]]
 +
 
 +
==References==
 +
[http://en.wikipedia.org/wiki/Pearson_product-moment_correlation_coefficient  Pearson]
 +
 
 +
 
 +
 
 +
 
 +
*[[Z_API_Functions | List of Main Z Functions]]
 +
 
 +
*[[ Z3 |  Z3 home ]]

Latest revision as of 17:11, 8 August 2018

RSQ (Array1,Array2)


  • is the array of y values.
  • is the array of x values.
    • RSQ(), returns the square of the Pearson product moment correlation coefficient.


Description

  • This function gives the square of Pearson Product Moment Correlation Coefficient.
  • This function is calculated using the data points of and values.
  • The formula for PPMC, is defined by:

where and are Average of the two Samples and .

  • This function gives the value of , which is the square of this Correlation Coefficient.
  • The square value can be interpreted as the proportion of the variance in attributable to the variance in .
  • In , the value of and must be either numbers or names, array, constants or references that contain numbers.
  • Suppose the array contains text, logicl values or empty cells, like that values are not considered.
  • This function will return the result as error when
1.  and  are empty or having the different number of data points.
2. The arguments having only one data point.
3. The arguments that are error values or text that cannot be translated in to numbers.

Refer PEARSON for more details.

Examples

Spreadsheet
A B C D E F G H
1 12 10 17 21 25 31 19 5
2 4 37 8 18 0 13 15 41
3 9 7 23 11 22 30 6 15
4 50 47 26 13 20 14 33 1
5 4 17 25 44 2 9 -1
6 18 36 40 11
  1. =RSQ(A1:A6,B1:B6) = 0.4003286578
  2. =RSQ(C1:C6,D1:D6) = 0.02320694105
  3. =RSQ(E1:H1,E2:H2) = 0.72060025461
  4. =RSQ(E3:E5,G3:G5) = 0.346037364910
  5. =RSQ(G3:G5,H3:H4) = NAN

Related Videos

RSQ

See Also

PEARSON

References

Pearson